DDS for printer files


TIMFMT (Time Format) keyword in printer files

Use this field-level keyword to specify the format of a time field. This keyword is valid for time fields (data type T).

The format of the keyword is:

TIMFMT(time-format)

The following table describes the valid time formats and their default separators.

Format Name Time Format Parameter Time Format and Separator Field Length Example
Hours:Minutes:Seconds
*HMS
hh:mm:ss
8
14:00:00
International
Standards Organization
*ISO
hh.mm.ss
8
14.00.00
IBM USA Standard
*USA
hh:mm AM or
hh:mm PM
8
2:00 pm
IBM European Standard
*EUR
hh.mm.ss
8
14.00.00
Japanese Industrial
Standard Christian Era
*JIS
hh:mm:ss
8
14:00:00

If you do not specify the TIMFMT keyword, the default is *ISO.

If you specify the time-format parameter value as *ISO, *USA, *EUR, or *JIS, you may not specify the TIMSEP keyword. These formats have fixed separators.

The TIMFMT keyword overrides the job attribute for a time field. It does not change the system default.

It is the responsibility of the high-level language and the application to format the time field according to the format specified for the TIMFMT keyword and use the separators specified on the TIMSEP keyword. The system does not format fields on output. The system validates the time field on input according to the format that the TIMFMT keyword specifies and the separator that the TIMSEP keyword specifies.

Option indicators are not valid for this keyword, although option indicators may condition the field for which it is specified.

Example:

The following example shows how to specify the TIMFMT keyword.

|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8
00010A
00020A          R RECORD
00030A            TIMFLD1         T  B  5  2TIMFMT(*ISO)
00040A            TIMFLD2         T  B  5 22TIMFMT(*USA)
00050A            TIMFLD3         T  B  5 42TIMFMT(*HMS) TIMSEP(',')
     A

If you want to display 2 o'clock p.m., the following values appear where RECORD1 is written.

TIMFLD1    14.00.00
TIMFLD2    02:00 PM
TIMFLD3    14,00,00


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]