In MariaDB, CURRENT_USER()
is a built-in function that returns the user name and host name combination for the MariaDB account that the server used to authenticate the current client.
Category: DBMS
Database Management Systems
MariaDB USER() Explained
In MariaDB, USER()
is a built-in function that returns the current MariaDB user name and host name, given when authenticating to MariaDB.
4 Functions to Return the Year from a Date in MariaDB
Below are 4 functions that enable you to return the year from a date in MariaDB. Three functions return just the year, and one returns both the year and week.
Continue readingMariaDB CONNECTION_ID() Explained
In MariaDB, every thread (including each event) has an ID that is unique among the set of currently connected clients. The CONNECTION_ID()
function is a built-in function that returns the connection ID (thread ID) for the connection.
MariaDB String Functions (Full List)
This article contains a full list of built-in MariaDB string functions and operators.
Continue readingMariaDB BENCHMARK() Explained
In MariaDB, BENCHMARK()
is a built-in function that executes an expression a specified number of times.
It can be used to time how quickly MariaDB processes the expression.
The result is always 0
. The function is intended to be used within the mysql command line tool, which reports query execution times.
How to Run SHOW LOCALES in MariaDB
If you’re trying to run SHOW LOCALES
but it’s not working, it’s probably because the LOCALES
plugin hasn’t been installed yet. Installing that plugin should hopefully fix the problem.
MariaDB Date & Time Functions (Full List)
This article contains a full list of built-in MariaDB date and time functions.
Continue readingGet the Language Currently Being Used in SQL Server
There are several ways to get the language currently being used in SQL Server.
The language of the current session will often be the default language for the login, but this is not necessarily always the case. A user can change the current language during the session.
Also, some of SQL Server’s built-in functions accept an argument that allows you to specify a language for that specific query.
This article shows you how to return the language currently being used.
Continue readingHOUR() vs EXTRACT(HOUR …) in MariaDB: What’s the Difference?
MariaDB has an HOUR()
function that extracts the hour portion from a time value. MariaDB also has an EXTRACT()
function that can also extract the hour portion from a time value.
However, these functions don’t always return the same result.
Read on to see the difference between HOUR()
and EXTRACT(HOUR FROM ...)
in MariaDB.