FORMATTIME command
Transforms the absolute date and time into any of a variety of formats. In Smalltalk, the parameters of the FORMATTIME command are contained in two classes: CICSFormattime and CICSFormattimeResult.
See CICS Application Programming Reference for the syntax of the command and a description of its parameters.
Defined instance methods
Parameters supplied to CICS in CICSFormattime
 
Parameter
Instance method
Mode
Type
Notes/exceptions
ABSTIME(data-area)
abstime:
Input
Packed(8)
 
DATESEP(data-value)
datesep:
Input
Fixed(1)
 
TIMESEP(data-value)
timesep:
Input
Fixed(1)
 
Parameters returned by CICS in CICSFormattimeResult
 
Parameter
Instance method
Mode
Type
Notes/exceptions
DATE(data-area)
date
Output
Fixed(8)
 
DATEFORM(data-area)
dateform
Output
Fixed(6)
 
DAYCOUNT(data-area)
daycount
Output
Binary 32
 
DAYOFMONTH(data-area)
dayofmonth
Output
Binary 32
 
DAYOFWEEK(data-area)
dayofweek
Output
Binary 32
 
DDMMYY(data-area)
ddmmyy
Output
Fixed(8)
 
DDMMYYYY(data-area)
ddmmyyyy
Output
Fixed (10)
 
MMDDYY(data-area)
mmddyy
Output
Fixed(8)
 
MMDDYYYY(data-area)
mmddyyyy
Output
Fixed (10)
 
MONTHOFYEAR(data-area)
monthofyear
Output
Binary 32
 
RESP
resp
Output
Fixed(2)
Inherited from CICSResult.
RESP2
resp2
Output
Fixed(2)
Inherited from CICSResult.
TIME(data-area)
time
Output
Fixed(8)
 
YEAR(data-area)
year
Output
Binary 32
 
YYDDD(data-area)
yyddd
Output
Fixed(6)
 
YYDDMM(data-area)
yyddmm
Output
Fixed(8)
 
YYMMDD(data-area)
yymmdd
Output
Fixed(8)
 
YYYYDDD(data-area)
yyyyddd
Output
Fixed (8)
 
YYYYDDMM(data-area)
yyyyddmm
Output
Fixed (10)
 
YYYYMMDD(data-area)
yyyymmdd
Output
Fixed (10)
 
Example
Formats the date and time, with separators, and displays the date in the format MMDDYY on the Transcript.
| result abstime |
result := CICS asktime exec.
abstime := result abstime.
result := CICS formattime
abstime: abstime;
datesep: $/;
timesep: $:;
exec.
Transcript show: (result mmddyy).
Last modified date: 07/09/2019