18.08.2013 Views

LINC Programming Reference Manual - Public Support Login - Unisys

LINC Programming Reference Manual - Public Support Login - Unisys

LINC Programming Reference Manual - Public Support Login - Unisys

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

DATE.CONVERT (DC)<br />

$ If the year is less than the GLB.CENTURY-START year, GLB.CENTURY is the<br />

following century.<br />

Once GLB.CENTURY has been set to a value other than 0 or the century of the base year, it<br />

remains set until explicitly changed or an invalid date is entered.<br />

Examples<br />

For example, GLB.CENTURY-START is 1957 (the same as GLB.BASE) and GLB.CENTURY<br />

is 0 (or 19).<br />

$ The years 57 through 99 represent 1957 through 1999.<br />

$ The years 00 through 56 represent 2000 through 2056.<br />

If you perform a date conversion with a year 50 followed by years of 60 and 70, andthe<br />

DC; sets GLB.CENTURY field on the Primary Options screen is set to Y, the date<br />

conversion will set GLB.CENTURY to 20 (as 1950 is prior to the value of<br />

GLB.CENTURY-START), and the years are interpreted as 2050, 2060, and2070.<br />

Special Date Conversions<br />

Date conversion of the values of the following six-digit dates will not use GLB.CENTURY.<br />

The current century will be used.<br />

$ GLB.TODAY (TODAY)<br />

$ GLB.TODAYS-DATE-NUM (TODAYS-DATE-NUM)<br />

$ GLB.YYMMDD<br />

$ INPUT-DATE<br />

Invalid Input Dates<br />

If the date involved is invalid, GLB.STATUS is set to *****. Alternatively, the GLB.STATUS;<br />

command may be used to direct the result to a data item. It is important to test for an error<br />

whenever the DATE.CONVERT; command is used.<br />

GLB.STATUS is set to five asterisks (*****) under any one of the following circumstances:<br />

$ Invalid input date is supplied, for example 31 February 1998.<br />

$ Input date is prior to the start of the GLB.BASE year.<br />

Note: GLB.CENTURY may be adjusted automatically to ensure that the<br />

date is valid. For details, see ‘‘Use of GLB.BASE and<br />

GLB.CENTURY’’, earlier in this section.<br />

If GLB.STATUS is set to five asterisks, date conversion is still performed, but using the<br />

current date. If the current date is invalid (for example, it is prior to the start of the base<br />

year), then 1 January of the base year is used as input.<br />

v 1-77

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!