How to: |
The WRTSTIME function accepts a date and time in one of five formats and converts the value to native OpenVMS 64-bit DEC Date/Time format. This allows the storage of native DEC Date/Time values in data sources such as RMS files and Rdb database tables that use this native format.
WRTSTIME(formatstyle, infield, output)
where:
Integer
Is a number from 0 to 4, from the list below, that corresponds to the desired formatting styles for infield.
0 denotes DD-MMM-YYYY HH:MM:SS
1 denotes DD-MMM-YYYY
2 denotes HH:MM:SS
3 denotes DD-MMM-YYYY HH:MM:SS.CC
4 denotes YYYY-MM-DD HH:MM:SS.CC
Alphanumeric
Is the name of a field containing the user-supplied date and/or time string to be converted. The expected length of infield is determined by the formatstyle as listed below.
Format Style Number | Byte Length |
---|---|
0 | 20 |
1 | 11 |
2 | 8 |
3 | 23 |
4 | 22 |
A8
Is the field that contains the result, or the format of the output value enclosed in single quotation marks.
WebFOCUS |