Introduction
In this project, you will learn how to create a custom function in MySQL that returns the larger of two given numbers. This project will guide you through the process of accessing MySQL, importing data, and developing a function to perform a maximum value judgment.
ð Preview
MariaDB [edusys]> SELECT getMax(1, 3);
+--------------+
| getMax(1, 3) |
+--------------+
| 3 |
+--------------+
1 row in set (0.001 sec)
ðŊ Tasks
In this project, you will learn:
- How to access MySQL using the
sudo
command without a password - How to import data from an SQL script into MySQL
- How to create a custom function in MySQL that takes two integers as input and returns the larger value
ð Achievements
After completing this project, you will be able to:
- Understand how to work with MySQL and create custom functions
- Develop a function to perform a maximum value judgment
- Apply your MySQL knowledge to solve practical problems