I am attempting to take an SMF binary time field that counts from midnight in 100th of seconds. I was able to break down the time to hours, minutes and seconds however when I go to print it I lose leading 0s if the time is less then 10. I tried to use the format command but it did not work.. any hints on how to do this.
85 *-* start_time = C2D(SUBSTR(SMFRECORD.3,C2D(S1R)-3+96,4))
86 *-* say "START time is " start_time
START time is 1490447
87 *-* time_var = start_time/(60*60*100)
88 *-* parse var time_var hours "." extra
89 *-* time_var = (start_time/(60*100)) - hours*60
90 *-* parse var time_var minutes "." extra
91 *-* time_var = (start_time/(100)) - (hours*3600 + minutes *60)
92 *-* parse var time_var seconds "." extra
93 *-* say "Time is "format(hours,2,0,'0','0')":"format(minutes,2,0,0,0)":"format(seconds,2,0,0,0)
Time is 4: 8:24
94 *-* "EXECIO 0 DISKR IN (FINIS"
>>> "EXECIO 0 DISKR IN (FINIS"