The latest Micro Focus products (3.4, 4.0 and NetExpress) support the new
ACCEPT x FROM DATE syntax which will return a four digit year. The
syntax is as follows:
...
ACCEPT x FROM DATE YYYYMMDD.
...
Where x is a PIC X(8) or equivalent.
Hope this helps.
Paddy Coleman
Team Leader, Distributed Computing Support (WinTel)
Micro Focus International.
Quote:
>>Anyone have a good workaround for the fact that the ACCEPT identifier FROM
>>DATE command gives only two digits for the year? I'm coding some routines
to
>>timestamp output files and would feel sort of stupid if they "expire" in
three
>>years.
>Check to see if your COBOL utilizes the intrinsic function CURRENT-DATE.
>VAX COBOL has since version 5.0. It's format is MOVE FUNCTION CURRENT-DATE
>TO <variable>. It returns a 21 byte alphanumeric field with the first 4
>bytes being the four numeric digits of the year, then 2 for month, then 2
>for day then the time in the form hh:mm:ss.nn in the next 8. The last five
>digits are returned as 00000 and are reserved for future use.
>If not see what type of system library calls you could make to retrieve the
>century digits.
>>What are Y2K programmers doing to get around this?
>I'm using the intrinsic function.
>Good luck as I get back to the Y2K business at hand.....
>Sallie
>===========================================================================
=====
> Think of me what you will | Sallie Kudra, Applications Analyst
II
> I've got a little space to fill... | ISD, Clemson University, Clemson, SC
>===========================================================================
=====