View previous topic :: View next topic
|
Author |
Message |
dejunzhu
Active User
Joined: 08 May 2008 Posts: 390 Location: China
|
|
|
|
What's the relationship between DB2 time and system time?
If system time changes, will DB2 time change?
or, DB2 time is retrieved by a special engine that owned by DB2 itself?
What if I changed the current time of DB2? should I stop DB2 first? |
|
Back to top |
|
|
gylbharat
Active Member
Joined: 31 Jul 2009 Posts: 565 Location: Bangalore
|
|
|
|
How will you change DB2 system time? I think DB2 picks time from system. |
|
Back to top |
|
|
dejunzhu
Active User
Joined: 08 May 2008 Posts: 390 Location: China
|
|
|
|
gylbharat wrote: |
How will you change DB2 system time? I think DB2 picks time from system. |
my data is processed by order of TIMESTAMP when it was inserted, if someone changes system time, there might be impact on my processing. So, I care about it.
I cannot find some useful information from DB2 redbook, so, I hope some one could help me on this.
thanks. |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3073 Location: NYC,USA
|
|
|
|
The CURRENT DATE special register gives the current system date. This can be used in select statements or more directly using the VALUES statement.
Quote: |
DB2 time is retrieved by a special engine that owned by DB2 itself? |
I don't think there is any special engine, the values or sysibm.sysdummy1 gives the date from the current server. |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3073 Location: NYC,USA
|
|
|
|
Quote: |
my data is processed by order of TIMESTAMP when it was inserted, if someone changes system time, there might be impact on my processing. So, I care about it. |
And can you give us a case? |
|
Back to top |
|
|
dejunzhu
Active User
Joined: 08 May 2008 Posts: 390 Location: China
|
|
|
|
for instance, I will process data exactly in the acending order of timestamp when data was inserted, but if someone changes the time to a earlier point, the following data inserted in a period of time will never be processed. This is a problem. |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
It seems you're describing a Daylight Saving change. If this is true, when you fallback, most shops stop processing for one-hour.
When you move forward, you'll see a one-hour difference in timestamps between the timestamp prior to moving forward and the updated timestamp after moving forward. This movement is normally based upon the Greenwhich Mean Time offset.
The DSN where the GMT offset is set, is usually SYS1.PARMLIB. But, I can't recall the member name. Your z/OS System Programmer would know the member nanme.
If you find the member name, look at the last USERID who updated it.
If someone in your shop is altering the timestamp (this is at the Operating System level) without authorization or without any legitimate reason (possibly malicious), you better find out who this is, before he/she really screws up the works.
HTH.... |
|
Back to top |
|
|
dejunzhu
Active User
Joined: 08 May 2008 Posts: 390 Location: China
|
|
|
|
Thanks, Bill.
So, you are telling that DB2 time is retrieved from system time. |
|
Back to top |
|
|
|