Skip to main content
Version: v1.6

Functions

The table below lists the support for functions in DQL and DML statements. It is important to note that functions cannot be used as primary keys in DML statements.

DML Statement Support

TypeSupported or not
CONCAT(string2[,...])Yes
INSTR(string,substring)Yes
LCASE(string2)Yes
LEFT(string2,length)Yes
LENGTH(string)Yes
LOAD_FILE(file_name)Yes
LOCATE(substring,string[,start_position])Yes
LPAD(string2,length,pad)Yes
LTRIM(string2)Yes
REPEAT(string2,count)Yes
REPLACE(str,search_str,replace_str)Yes
RPAD(string2,length,pad)Yes
RTRIM(string2)Yes
STRCMP(string1,string2)Yes
SUBSTRING(str,position[,length])Yes
TRIM([[BOTH|LEADING|TRAILING][padding]FROM]string2)Yes
UCASE(string2)Yes
RIGHT(string2,length)Yes
SPACE(count)Yes
ABS(number2)Yes
BIN(decimal_number)Yes
CEILING(number2)Yes
CONV(number2,from_base,to_base)Yes
FLOOR(number2)Yes
FORMAT(number,decimal_places)Yes
HEX(DecimalNumber)Yes
LEAST(number,number2[,..])Yes
MOD(numerator,denominator)Yes
POWER(number,power)Yes
RAND([seed])Yes
ROUND(number[,decimals])Yes
SIGN(number2)Yes
SQRT(number2)Yes
ADDTIME(date2,time_interval)Yes
CONVERT_TZ(datetime2,fromTZ,toTZ)Yes
CURRENT_DATE()Yes
CURRENT_TIME()Yes
CURRENT_TIMESTAMP()Yes
DATE(datetime)Yes
DATE_ADD(date2,INTERVALd_valued_type)Yes
DATE_FORMAT(datetime,FormatCodes)Yes
DATE_SUB(date2,INTERVALd_valued_type)Yes
DATEDIFF(date1,date2)Yes
DAY(date)Yes
DAYNAME(date)Yes
DAYOFWEEK(date)Yes
DAYOFYEAR(date)Yes
EXTRACT(interval_nameFROMdate)Yes
MAKEDATE(year,day)Yes
MAKETIME(hour,minute,second)Yes
MONTHNAME(date)Yes
NOW()Yes
SEC_TO_TIME(seconds)Yes
STR_TO_DATE(string,format)Yes
TIMEDIFF(datetime1,datetime2)Yes
TIME_TO_SEC(time)Yes
WEEK(date_time[,start_of_week])Yes
YEAR(datetime)Yes
DAYOFMONTH(datetime)Yes
HOUR(datetime)Yes
LAST_DAY(date)Yes
MICROSECOND(datetime)Yes
MONTH(datetime)Yes
MINUTE(datetime)Yes
FIRST()No
LAST()No
MIN()No
MAX()No
AVG()No
SUM()No
COUNT()No

DQL Statement Support

TypeRead UncommittedRead Committed
CONCAT(string2[,...])YesYes
INSTR(string,substring)YesYes
LCASE(string2)YesYes
LEFT(string2,length)YesYes
LENGTH(string)YesYes
LOAD_FILE(file_name)YesYes
LOCATE(substring,string[,start_position])YesYes
LPAD(string2,length,pad)YesYes
LTRIM(string2)YesYes
REPEAT(string2,count)YesYes
REPLACE(str,search_str,replace_str)YesYes
RPAD(string2,length,pad)YesYes
RTRIM(string2)YesYes
STRCMP(string1,string2)YesYes
SUBSTRING(str,position[,length])YesYes
TRIM([[BOTH|LEADING|TRAILING][padding]FROM]string2)YesYes
UCASE(string2)YesYes
RIGHT(string2,length)YesYes
SPACE(count)YesYes
ABS(number2)YesYes
BIN(decimal_number)YesYes
CEILING(number2)YesYes
CONV(number2,from_base,to_base)YesYes
FLOOR(number2)YesYes
FORMAT(number,decimal_places)YesYes
HEX(DecimalNumber)YesYes
LEAST(number,number2[,..])YesYes
MOD(numerator,denominator)YesYes
POWER(number,power)YesYes
RAND([seed])YesYes
ROUND(number[,decimals])YesYes
SIGN(number2)YesYes
SQRT(number2)YesYes
ADDTIME(date2,time_interval)YesYes
CONVERT_TZ(datetime2,fromTZ,toTZ)YesYes
CURRENT_DATE()YesYes
CURRENT_TIME()YesYes
CURRENT_TIMESTAMP()YesYes
DATE(datetime)YesYes
DATE_ADD(date2,INTERVALd_valued_type)YesYes
DATE_FORMAT(datetime,FormatCodes)YesYes
DATE_SUB(date2,INTERVALd_valued_type)YesYes
DATEDIFF(date1,date2)YesYes
DAY(date)YesYes
DAYNAME(date)YesYes
DAYOFWEEK(date)YesYes
DAYOFYEAR(date)YesYes
EXTRACT(interval_nameFROMdate)YesYes
MAKEDATE(year,day)YesYes
MAKETIME(hour,minute,second)YesYes
MONTHNAME(date)YesYes
NOW()YesYes
SEC_TO_TIME(seconds)YesYes
STR_TO_DATE(string,format)YesYes
TIMEDIFF(datetime1,datetime2)YesYes
TIME_TO_SEC(time)YesYes
WEEK(date_time[,start_of_week])YesYes
YEAR(datetime)YesYes
DAYOFMONTH(datetime)YesYes
HOUR(datetime)YesYes
LAST_DAY(date)YesYes
MICROSECOND(datetime)YesYes
MONTH(datetime)YesYes
MINUTE(datetime)YesYes
FIRST()YesNo
LAST()YesNo
MIN()YesNo
MAX()YesNo
AVG()YesNo
SUM()YesNo
COUNT()YesNo