SQL Useful Functions

SQL Useful Functions

SQL has many built-in functions for performing processing on string or numeric data. Following is the list of all useful SQL built-in functions

  • SQL COUNT Function - The SQL COUNT aggregate function is used to count the number of rows in a database table.
  • SQL MAX Function - The SQL MAX aggregate function allows us to select the maximum value for a certain column.
  • SQL MIN Function - The SQL MIN aggregate function allows us to select the minimum value for a certain column.
  • SQL AVG Function - The SQL AVG aggregate function selects the average value for certain table column.
  • SQL SUM Function - The SQL SUM aggregate function allows selecting the total for a numeric column.
  • SQL SQRT Functions - This is used to generate a square root of a given number.
  • SQL RAND Function - This is used to generate a random number using SQL command.
  • SQL CONCAT Function - This is used to concatenate any string inside any SQL command.
  • SQL Numeric Functions - Complete list of SQL functions required to manipulate numbers in SQL.
  • SQL String Functions - Complete list of SQL functions required to manipulate strings in SQL.



Why we can't execute a stored procedure from a User Defined function(UDF)

Functions cannot "touch" any database but read them only. Stored procedures can do anything and everything with databases. You ...