SQL Functions

SQL has built-in functions to perform certain calculations with higher performance.

AVG Returns the average value of a column.
COUNT Returns the number of rows in the query.
FIRST Returns the first value in the query.
LAST Returns the last value in the query.
MAX Returns the largest value in a column.
MIN Returns the smallest value in a column.
SUM Returns the sum of the values in a column.
GROUP BY Group rows with the same value in a column.
HAVING SQL functions include conditions.
UCASE Converts a value to uppercase.
LCASE Converts a value to lowercase.
MID Extract characters from a text field.
LEN Returns the length of a text field.
ROUND Rounds a numeric field to a specified number of decimal places.
NOW Returns the date and time of the system.
FORMAT Format a field as you want to display.