Export (0) Print
Expand All

ODBC Scalar Functions

Office 2007

Microsoft® Access SQL supports the use of the ODBC defined syntax for scalar functions. For example, the query:

SELECT DAILYCLOSE, DAILYCHANGE FROM DAILYQUOTE WHERE {fn ABS(DAILYCHANGE)} > 5

Would return all rows where the absolute value of the change in the price of a stock was greater than five.

A subset of the ODBC defined scalar functions is supported. The following table lists the functions that are supported.

For a description of the arguments and a complete explanation of the escape syntax for including functions in a SQL statement, see the ODBC documentation.

String Functions
ASCIILENGTHRTRIM
CHARLOCATESPACE
CONCATLTRIMSUBSTRING
LCASERIGHTUCASE
LEFT  
Numeric Functions
ABSFLOORSIN
ATANLOGSQRT
CEILINGPOWERTAN
COSRANDMOD
EXPSIGN 
Time & Date Functions
CURDATEDAYOFYEARMONTH
CURTIMEYEARWEEK
NOWHOURQUARTER
DAYOFMONTHMINUTEMONTHNAME
DAYOFWEEKSECONDDAYNAME
Data Type Conversion
CONVERTString literals can be converted to the following data types: SQL_FLOAT, SQL_DOUBLE, SQL_NUMERIC, SQL_INTEGER, SQL_REAL, SQL_SMALLINT, SQL_VARCHAR and SQL_DATETIME.
See Also

Configuring the Microsoft Access Database Engine for ODBC Access



Community Additions

ADD
Show:
© 2014 Microsoft