are built-in operations that perform specific tasks on data.
SQL FUNCTIONS
These functions can be used in SQL queries to manipulate, aggregate, or analyze data.
SQL Functions
are the one who work on single row and return one output per row.
Single Row Functions
For example, length and case conversion functions are __________
Singe Row Functions
work upon group of rows and return one result for the complete set of rows.
Multi-Row Functions
Multi-Row functions are also known as?
Group Functions
Accepts character input and returns number or character value.
Character Functions
What is the under the Character Functions
CONCAT
LENGTH
SUBSTR
INSTR
LPAD
RPAD
TRIM
REPLACE
What are the aggregate functions
AVG
SUM
COUNT
MAX
MIN
It returns the average of all values in the given column.
AVG()
What is the syntax for AVG
SELECT AVG(col_name) from table_name;
It returns the sum of all values in the given column.
SUM()
What is the syntax for SUM
SELECT SUM(< col_name >) from < table_name >;
It returns the no. of rows in the given column.
COUNT()
What is the syntax for COUNT
SELECT COUNT (< col_name >) from < table_name >
It selects the MAXIMUM value in the specified column.
MAX()
What is the syntax for MAX
SELECT MAX(< col_name >) from < table_name >;
It selects the MINIMUM value in the specified column.
MIN()
What is the Syntax for MIN
SELECT MIN(< col_name >) from < table_name >;
What are the types of string functions
UPPER(x)
LOWER(x)
INSTR
SUBSTR
CONCAT
LPAD
RPAD
It converts the string ‘X’ to UPPER case
UPPER(x)
It converts the string to ‘X’ to LOWER case
LOWER(x)
function returns numeric position of a character or a string in a given string.
INSTR
Returns the substring of given string starting from position integer ‘m’ and length integer ‘n’
SUBSTR(x,m,n)