PostgreSQL has a POSITION()
function that returns the first starting index of a specified substring within a string.
If the substring doesn’t exist in the string, then zero is returned.
Continue readingPostgreSQL has a POSITION()
function that returns the first starting index of a specified substring within a string.
If the substring doesn’t exist in the string, then zero is returned.
Continue readingIn PostgreSQL, RPAD()
is a function that enables us to add padding to the right part of a string.
In PostgreSQL, LPAD()
is a function that enables us to add padding to the left part of a string.
In PostgreSQL, the CONCAT_WS()
function concatenates two or more strings, placing a separator between each one. The separator is specified by the first argument.
In PostgreSQL, the CONCAT()
function concatenates the text representations of its arguments.
MariaDB has an INSTR()
function and also a LOCATE()
function. Both functions appear to do exactly the same thing – return the position of a substring within a string.
However, there is a difference.
Continue readingIf you need to replace a substring with another string in MariaDB, here are two approaches that you can use.
Continue readingMariaDB has an RTRIM()
function and a RTRIM_ORACLE()
function. Both functions do essentially the same thing. But there is a minor difference.
Below is a list of built-in string/character functions that are available in Oracle Database.
Continue readingIn Oracle, the TRANSLATE(...USING)
function converts its argument into the character set specified for conversions between the database character set and the national character set.
This function is not to be confused with the TRANSLATE()
function, which allows you to make several single-character, one-to-one substitutions in one operation.
The TRANSLATE(...USING)
function is supported in Oracle primarily for ANSI compatibility. Oracle recommends that we use the TO_CHAR()
and TO_NCHAR()
functions instead.