X 7.1.12 DATEVAL
X The DATEVAL function converts a non-date to a date field, for unambiguous
X use with date fields.
X If the DATEPROC compiler option is in effect, the returned value is a date
X field containing the value of argument-1 unchanged. For information on
X using the resulting date field:
X If the NODATEPROC compiler option is in effect, the DATEVAL function has
X no effect, and returns the value of argument-1 unchanged.
X The function type depends on the type of argument-1:
X Argument-1 Type Function Type
X Alphanumeric - Alphanumeric
X Integer - Integer
X ___ Format _____________________________________________________________
X | |
X | >>__FUNCTION DATEVAL__(__argument-1__argument-2__)__________________>< |
| |
|________________________________________________________________________|
X argument-1
X Must be one of the following:
- X A class alphanumeric item with the same number of characters as
X the date format specified by argument-2.
- X An integer. This can be used to specify values outside the range
X specified by argument-2, including negative values.
X The value of argument-1 represents a date of the form specified by
X argument-2.
X argument-2
X Must be a nonnumeric literal specifying a date pattern, as defined in
| "DATE FORMAT Clause" in topic 5.3.6. The date pattern consists of YY
| or YYYY (representing a windowed year or expanded year, respectively),
| optionally preceded or followed by one or more Xs (representing other
| parts of a date, such as month and day), as follows. Note that the
X values are case-insensitive; the letters X and Y in argument-2 may be
X any mix of uppercase and lowercase.
X Date-pattern string... Specifies that argument-1 contains...
X YY - A windowed (2-digit) year.
X YYYY - An expanded (4-digit) year.
| X - A single character; for example, a digit
| representing a semester or quarter (1-4).
X XX - Two characters; for example, digits
X representing a month (01-12).
X XXX - Three characters; for example, digits
X representing a day of the year (001-366).
X XXXX - Four characters; for example, 2 digits
X representing a month (01-12) and 2 digits
X representing a day of the month (01-31).
X Note: You can use apostrophes as the literal delimiters instead of
X quotes (independent of the APOST/QUOTE compiler option).
© Copyright IBM Corp. 1991, 1998
IBM Library Server Copyright 1989, 2005 IBM Corporation. All rights reserved.
Return to library:
z/OS |
z/OS.e |
TPF |
z/VSE |
z/VM |
IBM Hardware |
IBM System z Redbooks
Glossary:
IBM terminology
Publications:
How to order publications
Readers:
Download IBM Library Reader |
Download IBM Softcopy Reader |
Download Adobe® Acrobat® Reader®
Library management:
Download IBM Softcopy Librarian
Contacts:
Contact z/OS
Adobe, the Adobe logo, Acrobat, the Acrobat logo, and Acrobat Reader are registered trademarks
of Adobe Systems incorporated.