Enable/Disable Date Option

PURPOSE:  The DATE option controls the input and output format of date values.  The format may be American, International, or European.  The date must be one of the three types as DATE cannot be DISABLEd.  The other two date formats are automatically disabled when one is specified or the default format is in effect.  The default type is site dependent.  The keyword DATE can be placed before or after date type.  This command is valid in a CM, PM, SF and as a direct command.

SYNTAX

ENABLE DATE [AMERICAN; STANDARD; STD; INTERNATIONAL; ISO; EUR/OPEAN/]

[{IF; UNLESS} clause]

AMERICAN; STANDARD; STD

date storage formats, output forms, and input options are as follows:

D Data Type                   F Data Type  

Stored as                    YYMMDD           YYYYMMDD

Displayed as              MM/DD/YY         MM/DD/YYYY

Input forms allowed for either Data Type:

MM/DD/YY          MM-DD-YYYY

MM/DD/YYYY          YYMMDD   

MM-DD-YY          YYYYMMDD  

INTERNATIONAL; ISO date storage formats, output forms, and input options are as follows:

D Data Type                   F Data Type  

 Stored as                  YYMMDD            YYYYMMDD 

 Displayed as           YY-MM-DD          YYYY-MM-DD

Input forms allowed for either Data Type:

 YY/MM/DD          YYYY-MM-DD

YYYY/MM/DD           YYMMDD  

YY-MM-DD           YYYYMMDD 

EUR/OPEAN/

date storage formats, output forms, and input options are as follows:

                             D Data Type                    F Data Type

Stored as                 YYMMDD            YYYYMMDD

Displayed as           DD/MM/YY          DD/MM/YYYY

Input forms allowed for either Data Type:

 DD/MM/YY         DD-MM-YYYY 

             DD/MM/YYYY          YYMMDD   

              DD-MM-YY          YYYYMMDD  

{IF; UNLESS} clause

specifies certain criteria that must be met for the ENABLE or DISABLE command to take effect.

EXAMPLE

*TYPE @DATE
09/04/86
*ENABLE DATE ISO IF @STRING = “PARIS”
*TYPE @DATE
86-09-04

NOTES:  For all date options, the input forms with slashes (/) or dashes (-) do not require leading zeros for year, month, or day; for example, 5/5/91 or 05/05/91 can be entered.  The input forms without slashes or dashes require leading zeros: for example, 910505.

The system functions @CAL and @DVAL recognize and convert strings in any of the input forms.  However, when displayed, a value created with the @CAL function has the same form as an F (full date) field; i.e.  MM/DD/YYYY (optionally YYYY/MM/DD or DD/MM/YYYY).

Date formats may be specified with ENABLE in Command Modules (CM), Process Modules (PM), SF's and as a direct command.

See the system fields @CURRENCY_SIGN and @DECIMAL_POINT for similar conversions for international currency and decimal notation.

SEE ALSO:  @CAL, @DVAL - System Functions, and @CURRENCY_SIGN, @DECIMAL_POINT - System Fields