Sunday, March 25, 2012

May be Conditions...

Step1
Define your milestone job with an IN conditions for all jobs that you want to check like this:

1) Name of conditions for daily jobs: Jobx-Ok ODAT
2) Name of conditions for monthly jobs : #-Jobx-Month-Ok ODAT
3) Name of conditions for weekly jobs : #-Jobx-Week-Ok ODAT

<#-Condition name> is a prefix to define maybe contitions

Step 2
Define your jobs (weekly and monthly) with OUT condition to respect this convention prefix < #-Condition name >

Step 3
Define a job (Job1) to invoke the utility with parameter -CALCCOND -ADDMODE NO
This utility create a default output file in

Step 4
Define a job (Job2) to invoke the utility with parameter -LOAD "#-*"This utility read the conditions from a default file and load it on Conditions/Resources table

Important:
- Job1 and Job2 must be run after your
- Job2 must be run after Job1

See CTM_SERVER admin guide (utilities/ctmldnrs)

Example: Your daily milestone job check all regular daily conditions and conditions like < #-Condition name >

If a job with OUT conditions like < #-Condition name > not run due to schedule specifications you find this sysout for Job1

Job1

+ ctmldnrs -CALCCOND -ADDMODE NO

DEFAULT OUTPUT file is /soft/ctm01/ctm/tmp/ctmldnrs.dat
Previous output file /soft/ctm01/ctm/tmp/ctmldnrs.dat is deleted.
--------------------------------------------------------------
CONDNAME DATE ORDERNO JOBNAME
--------------------------------------------------------------
Q01-JOB37-BA-OK 0814 2600753 Q01-JOB13 \
#-F01-JOB14-OK 0814 2600655 F01-JOB05-I05 \
#-F01-JOB34-OK 0814 2600655 F01-JOB05-I05 \
#-Q01-EMM08-OK 0814 2600242 Q01-EMM14 \
#-Q01-EMM12-OK 0814 2600242 Q01-EMM14 \
Q01-AVAMO-H-OK 0814 2600770 Q01-FMC64-A05 \

After Job2 you find this in sysout for Job2

Job2

+ ctmldnrs -LOAD #-*

The INPUT file is /soft/ctm01/ctm/tmp/ctmldnrs.dat
+ ctmldnrs -LOAD #-*
Condition #-F01-JOB14-OK is loaded
Condition #-F01-JOB34-OK is loaded
Condition #-Q01-EMM08-OK is loaded
Condition #-Q01-EMM12-OK is loaded

The missing conditions < #-Condition name > was created (ADDED) because nothing jobs with this OUT conditions was scheduled and your milestone job can be executed

In finality the milestone job run every day with all IN conditions.
When the weekly or monthly jobs are scheduled the OUT conditions < #-Condition name > are posted by this jobs
When this jobs are not scheduled, the OUT conditions < #-Condition name > are posted by utility.

No comments:

Post a Comment