SET EPOCH Control the interpretation of dates with no century digits ------------------------------------------------------------------------------ Syntax SET EPOCH TO <nYear> Arguments TO <nYear> specifies the base year of a 100-year period in which all dates containing only two year digits are assumed to fall. Description SET EPOCH is an environment command that determines the interpretation of date strings containing only two year digits. When such a string is converted to a date value, its year digits are compared with the year digits of <nYear>. If the year digits in the date are greater than or equal to the year digits of <nYear>, the date is assumed to fall within the same century as <nYear>. Otherwise, the date is assumed to fall in the following century. The default value for SET EPOCH is 1900, causing dates with no century digits to be interpreted as falling within the twentieth century. Clipper supports all dates in the range 01/01/0100 to 12/31/2999. Examples . This example shows the effects of SET EPOCH: SET DATE FORMAT TO "mm/dd/yyyy" ? CTOD("05/27/1904") // Result: 05/27/1904 ? CTOD("05/27/67") // Result: 05/27/1967 ? CTOD("05/27/04") // Result: 05/27/1904 // SET EPOCH TO 1960 ? CTOD("05/27/1904") // Result: 05/27/1904 ? CTOD("05/27/67") // Result: 05/27/1967 ? CTOD("05/27/04") // Result: 05/27/2004 Files Library is CLIPPER.LIB.
See Also: CTOD() DATE() DTOC() DTOS() SET CENTURY SET DATE
Pingback: C5 UI Global Settings | Viva Clipper !
Pingback: C5 User Interface | Viva Clipper !
Pingback: C5 Commands | Viva Clipper !