skip to main content
Reference : SQL escape sequences for JDBC : Scalar Functions
  

Try DataDirect Drivers Now

Scalar Functions

You can use scalar functions in SQL statements with the following syntax:
{fn scalar-function}
where:
scalar-function
is a scalar function supported by the drivers, as listed in the following table.
Example:
SELECT id, name FROM emp WHERE name LIKE {fn UCASE('Smith')}
Table 28. Supported Scalar Functions
String Functions
Numeric Functions
Timedate Functions
System Functions
ASCII
BITLENGTH
CHAR
CHAR_LENGTH
CHARACTER_LENGTH
CONCAT
DIFFERENCE
HEXTORAW
INSERT
LCASE
LEFT
LENGTH
LOCATE
LOWER
LTRIM
OCTET_LENGTH
RAWTOHEX
REPEAT
REPLACE
RIGHT
RTRIM
SOUNDEX
SPACE
SUBSTR
SUBSTRING
UCASE
UPPER
ABS
ACOS
ASIN
ATAN
ATAN2
BITAND
BITOR
BITXOR
CEILING
COS
COT
DEGREES
EXP
FLOOR
LOG
LOG10
MOD
PI
POWER
RADIANS
RAND
ROUND
ROUNDMAGIC
SIGN
SIN
SQRT
TAN
TRUNCATE
CURDATE
CURTIME
DATEDIFF
DAY
DAYNAME
DAYOFMONTH
DAYOFWEEK
DAYOFYEAR
HOUR
MINUTE
MONTH
MONTHNAME
NOW
QUARTER
SECOND
TO_CHAR
WEEK
YEAR
CURSESSIONID
DATABASE
IDENTITY
USER