In MySQL, the ICU_VERSION()
function returns the version of the International Components for Unicode (ICU) library used to support regular expression operations.
The ICU_VERSION()
function is primarily intended for use in test cases.
In MySQL, the ICU_VERSION()
function returns the version of the International Components for Unicode (ICU) library used to support regular expression operations.
The ICU_VERSION()
function is primarily intended for use in test cases.
In MySQL, CURRENT_ROLE()
is a built-in function that returns the current active roles for the current session, separated by commas, or NONE
if there are none. The current role determines our access privileges.
In MySQL, the COERCIBILITY()
returns the collation coercibility value of its string argument.
The COERCIBILITY()
function defines how collations will be converted in the case of collation conflict. In such conflicts, an expression with a higher coercibility is converted to the collation of an expression with a lower coercibility.
The MySQL CONNECTION_ID()
function returns the connection ID (thread ID) for the connection.
In MySQL, every connection has an ID that is unique among the set of currently connected clients. We can use the CONNECTION_ID()
function to return that ID.
Some RDBMSs provide an easy way for us to find out how many rows were affected by the last SQL statement. This can be handy when running INSERT
, UPDATE
, or DELETE
statements.
The method used depends on the DBMS we’re using. Below, I look at how some of the major DBMSs implement this functionality.
Continue readingIn MySQL, BENCHMARK()
is a built-in function that executes an expression repeatedly for a specified number of times.
It can be used to time how quickly MySQL processes the expression. Specifically, the function is intended for measuring the runtime performance of scalar expressions.
The result is always 0
, or NULL
for inappropriate arguments. The function is intended to be used within the mysql
command line tool, which reports query execution times.
By default, time zone names aren’t included with MySQL. The MySQL installation process creates the appropriate tables, but it doesn’t populate these tables.
That said, it’s very easy to populate these tables.
Once populated, we can list out the time zone names available in our system by querying the mysql.time_zone_name
table.
In MySQL, COLLATION()
is a built in function that returns the collation of its string argument.
We provide the string when we call the function.
Continue readingIn MySQL, CHARSET()
is a built in function that returns the character set of its string argument.
We provide the string when we call the function.
Continue readingIf you’re getting an error in MySQL that reads something like “ERROR 1054 (42S22): Unknown column ‘c.DogName’ in ‘on clause”“, here are three likely causes: