3277061 – ABAP Date/Time Conversion with DST for SELECT_MESSAGES
DST (daylight saving time) starts in the spring (= a loss of one hour) and ends in the fall (= a gain of one hour ). For clock adjustment, one must remember “Spring forward, Fall back”.
Method 1: shut down the system
During the switch, simply shutdown the SAP system, for the entire duration of the double hour, and bring it up only after the double hour has passed. Thus, the SAP Kernel software does not have to deal with any possible mismatch of standard time and local time. The big setback off course is that you have work shutting down and starting up the systems in the middle of the night. And the business cannot work during this time. Long running weekend jobs might be interrupted as well and need to be redone.
Method 2: zero downtime by slowing down the time
Slow down the time by half, during the double hour, so that the 2 hour period is treated as one hour.
In SAP, executing this is easier than it appears by setting the parameter zdate/DSTswitch_contloctime = on which is default in the latest kernel release 6.40 and higher, so that you can make your SAP system see a continuous time with a deviation of 30 minutes.
During the conversion from summer time to winter time, there is a “doubled” hour. In Europe, for example, the summer time is reset to winter time on the last Sunday in October between 2 a.m. and 3 a.m.
1:00 1:30 2:00 2:30 2:00 2:30 3:00 official time
How to check the time zone at different levels
- Run the report from SA38: TZCUSTHELP (trouble shooting time zone)
- Run the report from SA38: RSDBTIME (time diagnosis)
- Run this function module in SE37: TZ_SYSTEM_GET_TZONE
- Run this report fromSA38: TZONECHECK
DST in non-ABAP systems
For DST in non-ABAP systems check these notes:
- 1367871 – Timezone updates for SAP JVM
- 1791342 – Time Zone Support in SAP HANA
- 2080216 – Check HANA DB for DST switch
Excellent blog from SAP: Daylight Saving Time and Slowing Down The Time.
Reference OSS notes:
- 7417 – Conversion between standard time and daylight saving time
- 950114 – Profile parameter zdate/DSTswitch_contloctime
- 102088 – Reducing downtime when changing from summer to winter time
- 198411 – Current data and information about time zones
- 1603349 – Downtime during DST time change
- 3015840 – Daylight saving time: best practices
ABAP programming DST specific notes: