Updating Dates and Times

From InterBase
Jump to: navigation, search

Go Up to Working with Dates and Times


To update a DATE, TIME, or TIMESTAMP data type in a table, you must convert it from the host-language format into InterBase format, and then store it. To convert a host variable into InterBase format, see Formatting Dates for Input. The actual update is performed using an UPDATE statement. For example,

EXEC SQL
UPDATE EMPLOYEE
SET DATE_OF_HIRE = :hire_date
WHERE DATE_OF_HIRE < '1 JAN 1994'

Advance To: