* The SETDAYLITE tool was removed in *
* V5R3 because the system provides *
* support. See WRKTIMZON. *
* The source for the SETDAYLITE tool *
* still exists in the TAA Archive, *
* but the objects are no longer *
* created in TAATOOL. *
* The tool cannot be created using *
* CRTTAATOOL. *
* If you are on V5R2, the Dec 2006 *
* or later version will update the *
* the TAADAYLITE Application Value *
* in TAASECURE and the TAADAYLITE *
* job schedule entry if it exists. *
* If you do not have the update, use *
* EDTAPPVAL APPVAL(TAASECURE/TAADAYLITE) *
* Change the values to *
* Start month 03 *
* Start day 1 *
* Start time 020000 *
* Start rel day 2 *
* End month 11 *
* End day 1 *
* End time 020000 *
* End rel day 1 *
* QUTCOFFSET - no change to your value *
* Then change the TAADAYLITE job *
* schedule entry schedule date to *
* '03/11/07' *
The Set Day Light Saving Time command allows you to set the system
for daylight saving time changes. The TAA function automatically
changes the time of day when daylight savings time starts and ends.
A job scheduling job (TAADAYLITE) is used to change the time of day
and then changes the job schedule entry for the next date. The
QUTCOFFSET system value may also be changed.
You must be authorized to CHGSYSVAL to use SETDAYLITE.
A typical command to set the automatic function would be:
This would cause the TAADAYLITE job to be scheduled at the next date
that day light saving should be set (either on or off). The default
dates and time are set for the USA. See the later discussion about
how to change the default dates.
Once SETDAYLITE has been issued, there should be no reason to ever
have to make a manual change for daylight savings time again. This
assumes that the dates and time for when daylight savings time starts
and end remain constant and you do not change the job schedule entry.
The TAADAYLITE job will keep re-submitting itself for the next date.
When the TAADAYLITE job runs, a program (TAADATRC2) is called. The
program waits for 2 minutes to allow system functions to complete if
IPL has just occurred. The program then determines whether to move
the QTIME system value forward or backward one hour. A message is
sent to QSYSOPR describing the change. The program then issues
SETDAYLITE which changes the TAADAYLITE job schedule job for the next
The TAADAYLITE job default is to run at 2:00 AM on the specified
date. The job schedule entry is specified as RCYACN(*SBMRLS) meaning
if the system is not powered up at that time, the job will be
released at the next IPL. See the later discussion of how the job
determines whether to change the QTIME system value.
Only a single job schedule entry by the name of TAADAYLITE can exist.
The TAA9888 message is sent to QSYSOPR to describe the change that
was made to the QTIME system value.
Refreshing the TAADAYLITE job schedule entry
Anytime the SETDAYLITE command is run, the TAADAYLITE job schedule
entry is added (if it does not exist) or changed. The date of the
job to be scheduled will be re-calculated as described earlier and
the user of SETDAYLITE becomes the profile for which the TAADAYLITE
job will be run under.
What happens if the USA standard dates/times change?
It is the intent of the TAA Productivity Tools product that if a
change occurred, the defaults will be changed when the product is
installed to the current USA standard dates and times. However, this
could only occur if you have installed a version of the product when
this change is included. If you have not done so, you must change
the values as described in the next section and then use SETDAYLITE.
The default values will only be changed by the install of the product
if the values exist as the old version of the USA standard.
Changing the default values for dates and times
The default values are set as follows:
On - 2:00 AM First Sunday in April
Off - 2:00 AM Last Sunday in October
The defaults are kept in the TAADAYLITE application value in
TAASECURE. If you need to change the defaults, as an *ALLOBJ user,
enter the command:
A prompt will appear with the start month, day, etc. Help text is
provided for the entries. Key in over the values that should be
changed. Then issue SETDAYLITE. If the TAADAYLITE job schedule
entry already exists, it will be changed. If it does not exist, an
entry will be added.
QUTCOFFSET System Value
The QUTCOFFSET system value determines the amount of time the system
clock differs from Greenwich time.
The major offsets in the US are:
Eastern time -05:00
Central time -06:00
Mountain time -07:00
Pacific time -08:00
The system value may also be adjusted by SETDAYLITE by specifying an
option in the TAADAYLITE application value in TAASECURE.
As an *ALLOBJ user, enter the command:
And specify 'Y' for the QUTCOFFSET adjustment.
The user of the SETDAYLITE command must be authorized to the
An error would occur if the user profile who adds a job schedule
entry does not exist when the job is actually run. In the case of
SETDAYLITE, the exposure of this is increased by the fact that the
job is seldom run.
To prevent this potential error, the job schedule entry is set as
USER(QSECOFR) to run under the profile of QSECOFR. Specifying
USER(QSECOFR) can only be done by a user who is authorized to the
QSECOFR user profile. To provide for this, all of the CL programs
for SETDAYLITE adopt the owners profile (QSECOFR).
Assume a user who does not have *ALLOBJ authority enters the
SETDAYLITE command. Once the job schedule entry is created, the
SETDAYLITE user cannot change any of the other parameters relative to
the entry as long as USER(QSECOFR) is specified. He can delete the
entry. He can change the USER value to a user profile he is
authorized to (such as himself) and then change any of the other
parameters. There are no known security exposures with this
How SETDAYLITE operates
When the SETDAYLITE command is run, it uses the sub program TAADATRC3
to retrieve the values from the TAADAYLITE Application Value in
TAASECURE. These values are used to determine the two dates during
the current year when a change must occur for daylight saving time.
The SETDAYLITE function then accesses the current date and determines
which of the two change dates is needed next. If the change will be
in the next year, the program determines the start date for the next
year. The date chosen is then used to schedule the TAADAYLITE job
schedule entry. If the job does not exist it is added. If it does
exist, the entry is changed. You may have only a single job named
If the current day is the same day as one of the change dates, the
current time is used to make a decision about which change date to
use. If the current time is within 5 minutes of the time the
TAADAYLITE job should be scheduled, the job will not be scheduled on
that day, but instead the next change date will be used.
The command submitted by the TAADAYLITE job is CALL
PGM(TAATOOL/TAADATRC2). This program uses the sub program TAADATRC3
to retrieve the TAADAYLITE Application Value and determines the two
dates of the current year when a change is needed. To allow for the
situation where the system may not be powered on when the change date
occurs, the program allows for a 2 week period following each of the
change dates. The current date must be within one of these two time
periods in order for a change to occur.
If TAADATRC2 is run outside of these two date ranges, a message is
sent to the message queue of the user of the job and to QSYSOPR
describing the situation.
If the current date is within the two week period for either date,
the CHGSYSVAL command is used for QTIME to set the value one hour
earlier or later depending on which change date is used.
If the system is not powered on when the TAADAYLITE job is to be
scheduled, the system will submit the job when the system is IPLed
(based on the job schedule parameter RCYACN = *SBMRLS). Since this
may occur at either the beginning or end of the day, it is possible
that the change to the QTIME system value will also require a change
to the QDATE system value. This is automatically provided for by the
At the completion of the TAADATRC2 program, the SETDAYLITE command is
executed which will determine the next date and change the TAADAYLITE
job schedule entry.
When daylight savings time goes 'on' (the clock is set to one hour
earlier), the technique used would cause the TAADATRC2 program to be
scheduled again and would keep resetting the clock one hour earlier.
To prevent this, a data area (TAADAYLITE) is used in TAATOOL which is
set to the current date whenever the time is changed. The SETDAYLITE
command retrieves the value in the data area and if the current date
is the same as the value in the data area (or the following day), it
changes the value of the current date to be 30 days in the future.
This forces the next change date to be used.
The TAADATRC2 program also retrieves the TAADAYLITE data area at the
beginning of processing and will not change the QTIME system value if
the change has already occurred on the current date (or the previous
Command parameters *CMD
JOBQ The qualified name of the job queue to be used. The
default is QBATCH. The library value defaults to
*LIBL. *CURLIB may also be used.
JOBD The qualified name of the job description to be
used. The default is QBATCH. The library value
defaults to *LIBL. *CURLIB may also be used.
The default dates and time of day to make the change are set for the
USA standard. You must change the Application Value provided if your
You must change the Application Value to cause the QUTCOFFSET system
value to be changed.
The user of the SETDAYLITE command must be authorized to the
There are some restrictions described in the method in which the
dates are calculated and exceptions are handled if the system is not
powered up when the change should occur.
The following TAA Tools must be on your system:
ADDDAT Add date
ADDTIM Add time
APPVAL Application value
CHKOBJ3 Check object 3
EDTVAR Edit variable
RSNLSTMSG Resend last message
RTVDAT Retrieve date
RTVDAT3 Retrieve date 3
RTVJOBSCDE Retrieve job schedule entry
SNDCOMPMSG Send completion message
SNDESCMSG Send escape message
None, the tool is ready to use. You must run the SETDAYLITE command
to submit the first use of the TAADAYLITE job.
Objects used by the tool
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
SETDAYLITE *CMD TAADATR QATTCMD
TAADATRC *PGM CLP TAADATRC QATTCL
TAADATRC2 *PGM CLP TAADATRC2 QATTCL
TAADATRC3 *PGM CLP TAADATRC3 QATTCL
The TAADAYLITE *USRSPC is in the TAASECURE library.
The TAADAYLITE job will be the name of the job schedule entry when
SETDAYLITE is run.