book
Article ID: KB0074840
calendar_today
Updated On:
Description
Using format-dateTime in BusinessWorks 5.x and 6.x is different.
If you print "tib:format-dateTime("yyyyMMddHHmmss",current-dateTime())" in BW 5.x, you will see an output resembling 20150807105204. This is as expected.
If you try to use the same string in BW6.x like format-dateTime(current-dateTime(), "yyyyMMddHHmmss"), it will print "yyyyMMddHHmmss" and not throw an error. This is not as expected.
Resolution
You will need to use the format-dateTime(current-dateTime(), "[Y0001][M01][D01][H01][m01][s01]") in BW 6.x to get the output below:
20150807105204
To get milliseconds and timezone: format-dateTime(current-dateTime(), "[Y0001][M01][D01][H01][m01][s01].[f001] [z]")
20200807015754.114 GMT-07:00
Issue/Introduction
Using format-dateTime in BusinessWorks 6.x.