Previous Topic: $ISPFSTAT()Next Topic: $SERVER()


$JUL2GREG()

This function converts a Julian-format date to Gregorian format.

Syntax

gregdate = $JUL2GREG(juldate)

Parameters

gregdate

Gregorian-format date: mm/dd/yy or mm/dd/yyyy. The number of digits that are assigned to the year are the same as specified in the Julian date. The month and day fields are two digits each, and are left-padded with a zero, if needed.

juldate

Julian-format date: yy.ddd or yyyy.ddd. The number of digits that are assigned to the year are carried over to the result and must be two or four. The number of digits that the day occupies is unimportant except that it must represent a valid date.

Return Codes

101

ARG 1 MISSING OR INVALID

121

INVALID YEAR

122

INVALID DAY

Example

$JUL2GREG('96.366')  ==  '12/31/96'
$GREG2JUL('2000.001') == '01/01/2000'