Previous Topic Next topic Print topic


TIME

Data Format

If a COBOL output host variable is defined for an SQL TIME value, the time is specified in the following format:
hh:mm:ss
For example:
12:34:00

Host Variable Formats

OpenESQL and DB2 ECM
01 time1         PIC X(8).
OpenESQL
01 time2         SQL TYPE IS TIME.
01 time3         SQL TYPE IS TIME-RECORD.
  • When using the time1 format:
    • OpenESQL requires that you compile applications with the DETECTDATE SQL directive.
    • Move time specifications into the host variable in the form:
      {t 'hh:mm:ss'} 
  • The time2 format uses the TIME SQL TYPE.
  • The time3 format uses the TIME-RECORD SQL TYPE.
Previous Topic Next topic Print topic