ODBC Server Reference Manual

CORE SQL Language
HP NonStop ODBC Server Reference Manual429151-002
3-12
Escape Clauses
Escape Clauses for Date and Time Data
For date, time, and timestamp data, described previously, ODBC uses the following
escape clauses:
D
specifies that value is a date in the “yyyy-mm-dd” format.
T
specifies that value is a time in the “hh:mm:ss” format.
TS
specifies that value is a timestamp in the “yyyy-mm-dd hh:mm:ss[.fff[fff]]”
format.
For example, each of the following statements updates the birthday of John Smith in
the EMPLOYEE table:
update employee
set birthday --*(vendor(Microsoft),product(ODBC) d '1939-01-27')*--
where name="Smith, John"
update employee
set birthday {d '1939-01-27'}
where name="Smith, John"
Note. The braces ( { and } ) in the preceding syntax do not follow the standard syntax
conventions indicating choice; they are actual characters you must enter.
--*( VENDOR(Microsoft), PRODUCT(ODBC) D value )*--
--*( VENDOR(Microsoft), PRODUCT(ODBC) T value )*--
--*( VENDOR(Microsoft), PRODUCT(ODBC) TS value )*--
or
{ D 'value' }
{ T 'value' }
{ TS 'value' }