Since V5R3, IBM has been working on updating the time support within the i operating system. You can see evidence of this with the time zone descriptions, which were introduced in V5R3. By using time-zone descriptions, you can allow the system to automatically adjust the system time for Daylight Saving Time (DST). But beyond the addition of time-zone descriptions and time adjustment, you haven’t seen other time-related changes in subsequent releases. However, much work has been done internally within the operating system to move to a Coordinated Universal Time (UTC)-based time system; in a UTC-based system, the date and time values are stored in UTC and converted to and from a job’s own time zone when displayed or changed by the user. This would ultimately allow different users in different time zones to work in their own local time.
As of the 6.1 release, IBM i doesn’t have the capability to support multiple time zones within a single LPAR. However, we do get a fair number of inquiries about supporting multiple time zones. Because of these requests, we determined that we needed to provide a solution that was “good enough” for the majority of the requests we received.
So with the 6.1 release, we worked with some tool partners to provide time simulation tools. These tools have existed on prior releases, but no longer worked on 6.1. And on the prior releases, the implementation approach was not one that IBM would support. However, in 6.1 these partners can now provide the time override capabilities in a manner that’s supported by IBM.
These time-simulation tools operate by overriding the date and time at the job level. These tools don’t provide job-level time zone support in every environment, but they do override the date and time in RPG, COBOL, DDS and most system display screens, APIs, etc. Functions that use cached timestamps or materialize timestamps directly don’t have the capability to be overridden and would continue to use the system time, or in the case of C and Java, use the time zone from the locale, if specified. As such, there are some limitations to these tools, which is why I said earlier that we worked to provide a solution that was “good enough” for many, and we do have customers using these tools successfully.
You can find additional information about these time simulation tools at the following links:
- AnyDate (link not active)
I’d like to thank Angela Newton for assisting with this blog post; Angela is the lead of the work management team and has been the key developer involved to provide the IBM i enablement in 6.1 for these time-simulation tools.
This blog post was originally published on IBMSystemsMag.com and is reproduced here by permission of IBM Systems Media.