What are Aggregate and Scalar capacities?
A total capacity performs activities on an accumulation of qualities to restore a solitary scalar worth. Total capacities are regularly utilized with the GROUP BY and HAVING provisions of the SELECT articulation. Following are the broadly utilized SQL total capacities:
AVG() – Calculates the mean of an accumulation of qualities.
Check() – Counts the absolute number of records in a particular table or view.
MIN() – Calculates the base of an accumulation of qualities.
MAX() – Calculates the limit of an accumulation of qualities.
Entirety() – Calculates the whole of an accumulation of qualities.
FIRST() – Fetches the main component in an accumulation of qualities.
LAST() – Fetches the last component in a gathering of qualities.
Note: All total capacities portrayed above disregard NULL qualities aside from the COUNT work.
A scalar capacity restores a solitary worth dependent on the information esteem. Following are the generally utilized SQL scalar capacities:
LEN() – Calculates the all out length of the given field (segment).
UCASE() – Converts an accumulation of string esteems to capitalized characters.
LCASE() – Converts a gathering of string esteems to lowercase characters.
MID() – Extracts substrings from a gathering of string esteems in a table.
CONCAT() – Concatenates at least two strings.
RAND() – Generates an irregular accumulation of quantities of given length.
ROUND() – Calculates the round off whole number an incentive for a numeric field (or decimal point esteems).
Presently() – Returns the present information and time.
Configuration() – Sets the organization to show an accumulation of qualities.