org.postgresql.jdbc
Class EscapedFunctions

java.lang.Object
  extended by org.postgresql.jdbc.EscapedFunctions

public class EscapedFunctions
extends Object

This class stores supported escaped function

Author:
Xavier Poinsard

Field Summary
static String ABS
           
static String ACOS
           
static String ASCII
           
static String ASIN
           
static String ATAN
           
static String ATAN2
           
static String CEILING
           
static String CHAR
           
static String CONCAT
           
static String COS
           
static String COT
           
static String CURDATE
           
static String CURTIME
           
static String DATABASE
           
static String DAYNAME
           
static String DAYOFMONTH
           
static String DAYOFWEEK
           
static String DAYOFYEAR
           
static String DEGREES
           
static String EXP
           
static String FLOOR
           
static String HOUR
           
static String IFNULL
           
static String INSERT
           
static String LCASE
           
static String LEFT
           
static String LENGTH
           
static String LOCATE
           
static String LOG
           
static String LOG10
           
static String LTRIM
           
static String MINUTE
           
static String MOD
           
static String MONTH
           
static String MONTHNAME
           
static String NOW
           
static String PI
           
static String POWER
           
static String QUARTER
           
static String RADIANS
           
static String REPEAT
           
static String REPLACE
           
static String RIGHT
           
static String ROUND
           
static String RTRIM
           
static String SECOND
           
static String SIGN
           
static String SIN
           
static String SPACE
           
static String SQL_TSI_DAY
           
static String SQL_TSI_FRAC_SECOND
           
static String SQL_TSI_HOUR
           
static String SQL_TSI_MINUTE
           
static String SQL_TSI_MONTH
           
static String SQL_TSI_QUARTER
           
static String SQL_TSI_ROOT
           
static String SQL_TSI_SECOND
           
static String SQL_TSI_WEEK
           
static String SQL_TSI_YEAR
           
static String SQRT
           
static String SUBSTRING
           
static String TAN
           
static String TIMESTAMPADD
           
static String TIMESTAMPDIFF
           
static String TRUNCATE
           
static String UCASE
           
static String USER
           
static String WEEK
           
static String YEAR
           
 
Constructor Summary
EscapedFunctions()
           
 
Method Summary
static Method getFunction(String functionName)
          get Method object implementing the given function
static String sqlceiling(List<?> parsedArgs)
          ceiling to ceil translation
static String sqlchar(List<?> parsedArgs)
          char to chr translation
static String sqlconcat(List<?> parsedArgs)
          concat translation
static String sqlcurdate(List<?> parsedArgs)
          curdate to current_date translation
static String sqlcurtime(List<?> parsedArgs)
          curtime to current_time translation
static String sqldatabase(List<?> parsedArgs)
          database translation
static String sqldayname(List<?> parsedArgs)
          dayname translation
static String sqldayofmonth(List<?> parsedArgs)
          dayofmonth translation
static String sqldayofweek(List<?> parsedArgs)
          dayofweek translation adding 1 to postgresql function since we expect values from 1 to 7
static String sqldayofyear(List<?> parsedArgs)
          dayofyear translation
static String sqlhour(List<?> parsedArgs)
          hour translation
static String sqlifnull(List<?> parsedArgs)
          ifnull translation
static String sqlinsert(List<?> parsedArgs)
          insert to overlay translation
static String sqllcase(List<?> parsedArgs)
          lcase to lower translation
static String sqlleft(List<?> parsedArgs)
          left to substring translation
static String sqllength(List<?> parsedArgs)
          length translation
static String sqllocate(List<?> parsedArgs)
          locate translation
static String sqllog(List<?> parsedArgs)
          log to ln translation
static String sqllog10(List<?> parsedArgs)
          log10 to log translation
static String sqlltrim(List<?> parsedArgs)
          ltrim translation
static String sqlminute(List<?> parsedArgs)
          minute translation
static String sqlmonth(List<?> parsedArgs)
          month translation
static String sqlmonthname(List<?> parsedArgs)
          monthname translation
static String sqlpower(List<?> parsedArgs)
          power to pow translation
static String sqlquarter(List<?> parsedArgs)
          quarter translation
static String sqlright(List<?> parsedArgs)
          right to substring translation
static String sqlrtrim(List<?> parsedArgs)
          rtrim translation
static String sqlsecond(List<?> parsedArgs)
          second translation
static String sqlspace(List<?> parsedArgs)
          space translation
static String sqlsubstring(List<?> parsedArgs)
          substring to substr translation
static String sqltimestampadd(List<?> parsedArgs)
          time stamp add
static String sqltimestampdiff(List<?> parsedArgs)
          time stamp diff
static String sqltruncate(List<?> parsedArgs)
          truncate to trunc translation
static String sqlucase(List<?> parsedArgs)
          ucase to upper translation
static String sqluser(List<?> parsedArgs)
          user translation
static String sqlweek(List<?> parsedArgs)
          week translation
static String sqlyear(List<?> parsedArgs)
          year translation
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ABS

public static final String ABS
See Also:
Constant Field Values

ACOS

public static final String ACOS
See Also:
Constant Field Values

ASIN

public static final String ASIN
See Also:
Constant Field Values

ATAN

public static final String ATAN
See Also:
Constant Field Values

ATAN2

public static final String ATAN2
See Also:
Constant Field Values

CEILING

public static final String CEILING
See Also:
Constant Field Values

COS

public static final String COS
See Also:
Constant Field Values

COT

public static final String COT
See Also:
Constant Field Values

DEGREES

public static final String DEGREES
See Also:
Constant Field Values

EXP

public static final String EXP
See Also:
Constant Field Values

FLOOR

public static final String FLOOR
See Also:
Constant Field Values

LOG

public static final String LOG
See Also:
Constant Field Values

LOG10

public static final String LOG10
See Also:
Constant Field Values

MOD

public static final String MOD
See Also:
Constant Field Values

PI

public static final String PI
See Also:
Constant Field Values

POWER

public static final String POWER
See Also:
Constant Field Values

RADIANS

public static final String RADIANS
See Also:
Constant Field Values

ROUND

public static final String ROUND
See Also:
Constant Field Values

SIGN

public static final String SIGN
See Also:
Constant Field Values

SIN

public static final String SIN
See Also:
Constant Field Values

SQRT

public static final String SQRT
See Also:
Constant Field Values

TAN

public static final String TAN
See Also:
Constant Field Values

TRUNCATE

public static final String TRUNCATE
See Also:
Constant Field Values

ASCII

public static final String ASCII
See Also:
Constant Field Values

CHAR

public static final String CHAR
See Also:
Constant Field Values

CONCAT

public static final String CONCAT
See Also:
Constant Field Values

INSERT

public static final String INSERT
See Also:
Constant Field Values

LCASE

public static final String LCASE
See Also:
Constant Field Values

LEFT

public static final String LEFT
See Also:
Constant Field Values

LENGTH

public static final String LENGTH
See Also:
Constant Field Values

LOCATE

public static final String LOCATE
See Also:
Constant Field Values

LTRIM

public static final String LTRIM
See Also:
Constant Field Values

REPEAT

public static final String REPEAT
See Also:
Constant Field Values

REPLACE

public static final String REPLACE
See Also:
Constant Field Values

RIGHT

public static final String RIGHT
See Also:
Constant Field Values

RTRIM

public static final String RTRIM
See Also:
Constant Field Values

SPACE

public static final String SPACE
See Also:
Constant Field Values

SUBSTRING

public static final String SUBSTRING
See Also:
Constant Field Values

UCASE

public static final String UCASE
See Also:
Constant Field Values

CURDATE

public static final String CURDATE
See Also:
Constant Field Values

CURTIME

public static final String CURTIME
See Also:
Constant Field Values

DAYNAME

public static final String DAYNAME
See Also:
Constant Field Values

DAYOFMONTH

public static final String DAYOFMONTH
See Also:
Constant Field Values

DAYOFWEEK

public static final String DAYOFWEEK
See Also:
Constant Field Values

DAYOFYEAR

public static final String DAYOFYEAR
See Also:
Constant Field Values

HOUR

public static final String HOUR
See Also:
Constant Field Values

MINUTE

public static final String MINUTE
See Also:
Constant Field Values

MONTH

public static final String MONTH
See Also:
Constant Field Values

MONTHNAME

public static final String MONTHNAME
See Also:
Constant Field Values

NOW

public static final String NOW
See Also:
Constant Field Values

QUARTER

public static final String QUARTER
See Also:
Constant Field Values

SECOND

public static final String SECOND
See Also:
Constant Field Values

WEEK

public static final String WEEK
See Also:
Constant Field Values

YEAR

public static final String YEAR
See Also:
Constant Field Values

TIMESTAMPADD

public static final String TIMESTAMPADD
See Also:
Constant Field Values

TIMESTAMPDIFF

public static final String TIMESTAMPDIFF
See Also:
Constant Field Values

SQL_TSI_ROOT

public static final String SQL_TSI_ROOT
See Also:
Constant Field Values

SQL_TSI_DAY

public static final String SQL_TSI_DAY
See Also:
Constant Field Values

SQL_TSI_FRAC_SECOND

public static final String SQL_TSI_FRAC_SECOND
See Also:
Constant Field Values

SQL_TSI_HOUR

public static final String SQL_TSI_HOUR
See Also:
Constant Field Values

SQL_TSI_MINUTE

public static final String SQL_TSI_MINUTE
See Also:
Constant Field Values

SQL_TSI_MONTH

public static final String SQL_TSI_MONTH
See Also:
Constant Field Values

SQL_TSI_QUARTER

public static final String SQL_TSI_QUARTER
See Also:
Constant Field Values

SQL_TSI_SECOND

public static final String SQL_TSI_SECOND
See Also:
Constant Field Values

SQL_TSI_WEEK

public static final String SQL_TSI_WEEK
See Also:
Constant Field Values

SQL_TSI_YEAR

public static final String SQL_TSI_YEAR
See Also:
Constant Field Values

DATABASE

public static final String DATABASE
See Also:
Constant Field Values

IFNULL

public static final String IFNULL
See Also:
Constant Field Values

USER

public static final String USER
See Also:
Constant Field Values
Constructor Detail

EscapedFunctions

public EscapedFunctions()
Method Detail

getFunction

public static Method getFunction(String functionName)
get Method object implementing the given function

Parameters:
functionName - name of the searched function
Returns:
a Method object or null if not found

sqlceiling

public static String sqlceiling(List<?> parsedArgs)
                         throws SQLException
ceiling to ceil translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqllog

public static String sqllog(List<?> parsedArgs)
                     throws SQLException
log to ln translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqllog10

public static String sqllog10(List<?> parsedArgs)
                       throws SQLException
log10 to log translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlpower

public static String sqlpower(List<?> parsedArgs)
                       throws SQLException
power to pow translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqltruncate

public static String sqltruncate(List<?> parsedArgs)
                          throws SQLException
truncate to trunc translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlchar

public static String sqlchar(List<?> parsedArgs)
                      throws SQLException
char to chr translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlconcat

public static String sqlconcat(List<?> parsedArgs)
concat translation

Parameters:
parsedArgs - arguments
Returns:
sql call

sqlinsert

public static String sqlinsert(List<?> parsedArgs)
                        throws SQLException
insert to overlay translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqllcase

public static String sqllcase(List<?> parsedArgs)
                       throws SQLException
lcase to lower translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlleft

public static String sqlleft(List<?> parsedArgs)
                      throws SQLException
left to substring translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqllength

public static String sqllength(List<?> parsedArgs)
                        throws SQLException
length translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqllocate

public static String sqllocate(List<?> parsedArgs)
                        throws SQLException
locate translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlltrim

public static String sqlltrim(List<?> parsedArgs)
                       throws SQLException
ltrim translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlright

public static String sqlright(List<?> parsedArgs)
                       throws SQLException
right to substring translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlrtrim

public static String sqlrtrim(List<?> parsedArgs)
                       throws SQLException
rtrim translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlspace

public static String sqlspace(List<?> parsedArgs)
                       throws SQLException
space translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlsubstring

public static String sqlsubstring(List<?> parsedArgs)
                           throws SQLException
substring to substr translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlucase

public static String sqlucase(List<?> parsedArgs)
                       throws SQLException
ucase to upper translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlcurdate

public static String sqlcurdate(List<?> parsedArgs)
                         throws SQLException
curdate to current_date translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlcurtime

public static String sqlcurtime(List<?> parsedArgs)
                         throws SQLException
curtime to current_time translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqldayname

public static String sqldayname(List<?> parsedArgs)
                         throws SQLException
dayname translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqldayofmonth

public static String sqldayofmonth(List<?> parsedArgs)
                            throws SQLException
dayofmonth translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqldayofweek

public static String sqldayofweek(List<?> parsedArgs)
                           throws SQLException
dayofweek translation adding 1 to postgresql function since we expect values from 1 to 7

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqldayofyear

public static String sqldayofyear(List<?> parsedArgs)
                           throws SQLException
dayofyear translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlhour

public static String sqlhour(List<?> parsedArgs)
                      throws SQLException
hour translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlminute

public static String sqlminute(List<?> parsedArgs)
                        throws SQLException
minute translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlmonth

public static String sqlmonth(List<?> parsedArgs)
                       throws SQLException
month translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlmonthname

public static String sqlmonthname(List<?> parsedArgs)
                           throws SQLException
monthname translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlquarter

public static String sqlquarter(List<?> parsedArgs)
                         throws SQLException
quarter translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlsecond

public static String sqlsecond(List<?> parsedArgs)
                        throws SQLException
second translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlweek

public static String sqlweek(List<?> parsedArgs)
                      throws SQLException
week translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlyear

public static String sqlyear(List<?> parsedArgs)
                      throws SQLException
year translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqltimestampadd

public static String sqltimestampadd(List<?> parsedArgs)
                              throws SQLException
time stamp add

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqltimestampdiff

public static String sqltimestampdiff(List<?> parsedArgs)
                               throws SQLException
time stamp diff

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqldatabase

public static String sqldatabase(List<?> parsedArgs)
                          throws SQLException
database translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqlifnull

public static String sqlifnull(List<?> parsedArgs)
                        throws SQLException
ifnull translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens

sqluser

public static String sqluser(List<?> parsedArgs)
                      throws SQLException
user translation

Parameters:
parsedArgs - arguments
Returns:
sql call
Throws:
SQLException - if something wrong happens


Copyright © 2016 PostgreSQL Global Development Group. All rights reserved.