![]() |
| CL command for Timestamp |
Sometimes there were the need of fetching the current system timestamp in the CLLE program. So, the question here is that is there any command in the CL that can give me the current system timestamp.
So, the answer here is Yes, you can very easily get the system timestamp in your CL program by just using the below CL script
PGM
DCL VAR(&TIMESTAMP) TYPE(*CHAR) LEN(20)
RTVSYSVAL SYSVAL(QDATETIME) RTNVAR(&TIMESTAMP)
RETURN
ENDPGM
