In MariaDB, REVERSE()
is a built-in string function that returns a string with the characters in reverse order.
The function accepts one argument: the string to reverse.
Continue readingIn MariaDB, REVERSE()
is a built-in string function that returns a string with the characters in reverse order.
The function accepts one argument: the string to reverse.
Continue readingIn MariaDB, REPLACE()
is a built-in string function that allows you to replace a part of a string with another string.
The function accepts three arguments: the string, the substring to replace, and the string to replace the substring with.
Continue readingIn MariaDB, POSITION()
is a built-in string function that returns the position of the first occurrence of a substring within another string. It’s part of ODBC 3.0.
POSITION(substr IN str)
is a synonym for LOCATE(substr,str)
.
POSITION()
is also similar to the INSTR()
function, except that POSITION()
uses the IN
syntax, and that the argument order is reversed between these two functions.
In MariaDB, SUBSTRING_INDEX()
is a built-in string function. It returns a substring from a string before a certain number of occurrences of the specified delimiter.
SUBSTRING_INDEX()
requires at three arguments; the string, the delimiter, and the count (i.e. number of occurrences of that delimiter).
In MariaDB, REPEAT()
is a built-in string function that returns a string repeated a certain number of times.
You pass the string, as well as the number of times you want it repeated when you call the function.
Continue readingIn MariaDB, QUOTE()
is a built-in string function that allows you to escape a string so that it’s suitable for inclusion in an SQL statement.
The string is returned enclosed by single quotes, and a backslash is prepended to each instance of single quote ('
), backslash (\
), ASCII NUL
, and Control-Z
characters.
In MariaDB, MID()
is a synonym for SUBSTRING()
. It returns a substring from a given string.
According to the MariaDB documentation it’s a synonym for the SUBSTRING(str,pos,len)
syntax of SUBSTRING()
, however, my tests show that it works with all of the various forms.
In MariaDB, SUBSTR()
is a synonym for SUBSTRING()
.
It’s a built-in string function that returns a substring from a given string.
It requires at least two arguments; the string, and the position for which to extract the substring from. It also accepts an optional third argument that allows you to specify how long the substring should be.
Continue readingIn MariaDB, SUBSTRING()
is a built-in string function that returns a substring from a given string.
SUBSTRING()
requires at least two arguments; the string, and the position for which to extract the substring from. It also accepts an optional third argument that allows you to specify how long the substring should be.
In MariaDB, MATCH AGAINST
is a special construct used to perform a full-text search on a full-text index.