In MariaDB, JSON_ARRAY() is a built-in function that returns a JSON array containing the specified values, provided as arguments.
what is
MariaDB CURRENT_ROLE() Explained
In MariaDB, CURRENT_ROLE() is a built-in function that returns the current role name. The current role determines your access privileges.
The output of SELECT CURRENT_ROLE is equivalent to the contents of the information_schema.ENABLED_ROLES table.
MariaDB ROW_COUNT() Explained
In MariaDB, ROW_COUNT() is a built-in function that returns the number of rows updated, inserted or deleted by the preceding statement.
The value returned by ROW_COUNT() is the same as the row count that the mysql client displays and the value from the mysql_affected_rows() C API function.
MariaDB LAST_INSERT_ID() Explained
In MariaDB, LAST_INSERT_ID() is a built-in function that returns the first automatically generated value successfully inserted for an AUTO_INCREMENT column as a result of the most recently executed INSERT statement.
It can also be called with an argument, in which case, it returns the value of the expression and the next call to LAST_INSERT_ID() will return the same value.
MariaDB JSON_TABLE() Explained
In MariaDB, JSON_TABLE() is a built-in function that converts JSON data into a relational form.
In other words, it lets you return a JSON document as a table.
The JSON_TABLE() function was introduced in MariaDB 10.6.0.
MariaDB LTRIM() vs LTRIM_ORACLE(): What’s the Difference?
MariaDB has an LTRIM() function and a LTRIM_ORACLE() function. Both functions do essentially the same thing. But there is a minor difference.
MariaDB DEFAULT() Explained
In MariaDB, DEFAULT() is a built-in function that returns the default value for a table column.
If the column has no default value and it is nullable, then NULL is returned. If the column has no default value and it is not nullable, an error is returned.
MariaDB ROWNUM() Explained
In MariaDB, ROWNUM() is a built-in function that returns the current number of accepted rows in the current context. Its main purpose is to emulate the ROWNUM pseudo column in Oracle.
ROWNUM() can be used in a way that has a similar effect to the LIMIT clause – to limit the number of results returned by a query.
When in Oracle mode, it can be called as ROWNUM (i.e. without the parentheses).
The ROWNUM() function is supported from MariaDB 10.6.1.
MariaDB VERSION() Explained
In MariaDB, VERSION() is a built-in function that returns the MariaDB server version.
The result is a string that uses the utf8 character set.
MariaDB FOUND_ROWS() Explained
In MariaDB, you can use the LIMIT clause to reduce the number of rows returned by a query. The FOUND_ROWS() function can be used in such queries to return the number of rows that would have been returned, had the LIMIT clause not been included.
This can be handy, because it allows you to get this information without having to run the query again.
The FOUND_ROWS() function can also be used to return the number of rows that were actually returned by the limited statement, if that’s what you need.