1 | input_seconds | Input | FLOAT8 |
2 | picture_string | Input | VSTRING |
3 | output_timestamp | Output | VSTRING |
4 | fc | Output | FEEDBACK |
The Convert Seconds to Character Timestamp (CEEDATM) API formats a number representing the number of seconds since 00:00:00 14 October 1582. The output is a character string such as 1988/07/26 20:37:00.
None.
Picture Characters Used in Picture Strings contains a list of valid picture characters, and Examples of Picture Strings Recognized by ILE Date and Time APIs has examples of valid picture strings.
If picture_string is null or blank, CEEDATM obtains picture_string based on the current job value for the country or region ID (CNTRYID). For example, if the current job value for CNTRYID is US (United States), the date-time format is MM/DD/YYYY HH:MI AP. If the current job value for CNTRYID is FR (France), the date-time format is YYYY-MM-DD HH.MI.
This default mechanism makes it easy for translators to specify the preferred timestamp format, and also easy for application programs and library procedures to automatically use this format.
CEE0000 | The API completed successfully |
Severity: 00 | |
CEE0501 | The operational descriptor data type is not valid |
Severity: 30 | |
CEE0502 | Missing operational descriptor |
Severity: 30 | |
CEE2505 | The value for seconds is out of range |
Severity: 30 | |
CEE2506 | The value for seconds is outside of era |
Severity: 30 | |
CEE2518 | The picture string specification is not valid |
Severity: 30 | |
CEE2527 | Timestamp truncated |
Severity: 30 | |
CEE9902 | Unexpected user error occurred in &1 |
Severity: 30 |
The inverse of CEEDATM is CEESECS. The CEESECS converts timestamp values to number-of-seconds values.
If the input value is a Lilian date instead of seconds, multiply the Lilian date by 86 400 (number of seconds in a day), and pass the new value to CEEDATM.
If picture_string includes the Japanese era symbol <JJJJ>, the YY position in output_timestamp is replaced by the year within Japanese era. Examples of Picture Strings Recognized by ILE Date and Time APIs has an example. Japanese Eras Used by ILE Date and Time APIs When <JJJJ> Specified contains a list of Japanese eras supported by CEEDATM.
If picture_string includes the Republic of China (ROC) era symbol <CCCC> or <CCCCCCCC>, the YY position in output_timestamp is replaced by the year within ROC era. See Examples of Picture Strings Recognized by ILE Date and Time APIs for an example. See Republic of China Eras Used by ILE Date and Time APIs When <CCCC> or <CCCCCCCC> Specified for a list of ROC eras supported by CEEDATM.
Sample Output of the CEEDATM API
input_seconds | picture_string | output_timestamp |
---|---|---|
12 799 191 601.000 |
YYMMDD HH:MI:SS YY-MM-DD YYMMDDHHMISS YY-MM-DD HH:MI:SS YYYY-MM-DD HH:MI:SS AP |
880516 19:00:01 88-05-16 880516190001 88-05-16 19:00:01 1988-05-16 07:00:01 PM |
12 799 191 661.986 |
DD Mmm YY DD MMM YY HH:MM WWW, MMM DD, YYYY ZH:MI AP Wwwwwwwwwz, ZM/ZD/YY HH:MI:SS.99 |
16 May 88 16 MAY 88 19:01 MON, MAY 16, 1988 7:01 PM Monday, 5/16/88 19:01:01.98 |
12 799 191 662.009 |
YYYY YY Y MM ZM RRRR MMM Mmm Mmmmmmmmmm Mmmmmmmmmz DD ZD DDD HH ZH MI SS 99 999 AP WWW Www Wwwwwwwwww Wwwwwwwwwz |
1988 88 8 05 5 V MAY May May May 16 16 137 19 19 01 02 00 009 PM MON Mon Monday Monday |
See Code disclaimer information for information pertaining to code examples.
Convert number of seconds to YYYY/MM/DD HH.MM.SS format:
CALL CEEDATM (secs, 'YYYY/MM/DD HH.MI.SS', timestmp, fc);
Top | ILE CEE APIs | APIs by category |