Quick Reference
This is a quick reference list of MySQL advanced functions and how they are used to work with databases.
- SQL – MySQL BIN() FunctionThe MySQL BIN() function returns a binary representation of a number, as a string value.
- SQL – MySQL BINARY FunctionThe MySQL BINARY function converts a value to a binary string.
- SQL – MySQL CASE FunctionThe MySQL CASE statement goes through conditions and will stop reading and return a value when the first condition in the list is met.
- SQL – MySQL CAST() FunctionThe MySQL CAST() function converts a value of any type into the specified datatype.
- SQL – MySQL COALESCE() FunctionThe MySQL COALESCE() function returns the first non-null value in a list.
- SQL – MySQL CONNECTION_ID() FunctionThe MySQL CONNECTION_ID() function returns the unique connection ID for the current connection.
- SQL – MySQL CONV() FunctionThe MySQL CONV() function converts a number from one numeric base system to another, and returns the result as a string value.
- SQL – MySQL CONVERT() FunctionThe MySQL CONVERT() function converts a value into the specified datatype or character set.
- SQL – MySQL CURRENT_USER() FunctionThe MySQL CURRENT_USER() function returns the user name and host name for the MySQL account that the server used to authenticate the current client.
- SQL – MySQL DATABASE() FunctionThe MySQL DATABASE() function returns the name of the current database. If there is no current database, this function returns NULL or “”.
- SQL – MySQL IF() FunctionThe MySQL IF() function returns a value if a condition is TRUE, or another value if a condition is FALSE.
- SQL – MySQL IFNULL() FunctionThe MySQL IFNULL() function returns a specified value if the expression is NULL.
- SQL – MySQL ISNULL() FunctionThe MySQL ISNULL() function returns 1 (null) or 0 (not null) depending on whether an expression is NULL.
- SQL – MySQL LAST_INSERT_ID() FunctionThe MySQL LAST_INSERT_ID() function returns the AUTO_INCREMENT id of the last row that has been inserted or updated in a table.
- SQL – MySQL NULLIF() FunctionThe MySQL NULLIF() function compares two expressions and returns NULL if they are equal. Otherwise, the first expression is returned.
- SQL – MySQL SESSION_USER() FunctionThe MySQL SESSION_USER() function returns the current user name and host name for the MySQL connection.
- SQL – MySQL SYSTEM_USER() FunctionThe MySQL SYSTEM_USER() function returns the current user name and host name for the MySQL connection.
- SQL – MySQL USER() FunctionThe MySQL USER() function returns the current user name and host name for the MySQL connection.
- SQL – MySQL VERSION() FunctionThe MySQL VERSION() function returns the current version of the MySQL database, as a string.
SQL Notes:
- Any work being done to modify the structure of a database or delete tables or the the database itself should only be done after making a recent backup
We’d like to acknowledge that we learned a great deal of our coding from W3Schools and TutorialsPoint, borrowing heavily from their teaching process and excellent code examples. We highly recommend both sites to deepen your experience, and further your coding journey. We’re just hitting the basics here at 1SMARTchicken.