Passing variable for comming friday

Tools and several solutions to manage Control-M products
Post Reply
User avatar
Dablu
Nouveau
Nouveau
Posts: 14
Joined: 12 Nov 2013 12:00

Passing variable for comming friday

Post by Dablu » 02 Jul 2015 4:52

Hi,
Env 8 on Windows

Need to pass comming friday for a job which will execute from Sunday to Thursday.

Sunday=ODATE date of friday
Mon.=ODATE date of friday
..
Thurs=ODATE date of friday

So how to define a job which will run daily to send a value to this variable .
In alternate way we have to create 5 jobs before the execution of full chain.so on sunday .
1st job will resolve the value of variable (%%\PARAM1 %%$ODATE %%$CALCDATE +4)
and we can pick the GL variable value of PARAM1 in the required job.

But in this type ,we need to define one one job for each day to pass the value to PARAM1.

So I am looking to define on a singe job .which will automatic resolve value of PARAM1
like

sunday it will (%%\PARAM1 %%$ODATE %%$CALCDATE +5)
monday (%%\PARAM1 %%$ODATE %%$CALCDATE +4)
tuesday (%%\PARAM1 %%$ODATE %%$CALCDATE +3)
wednees (%%\PARAM1 %%$ODATE %%$CALCDATE +2)
Thursday (%%\PARAM1 %%$ODATE %%$CALCDATE +1)


Thanks for your feedback on this.


=================================================

User avatar
mauriziog
Nouveau
Nouveau
Posts: 807
Joined: 08 Jun 2007 12:00
Location: Varese - Italy
Contact:

Re: Passing variable for comming friday

Post by mauriziog » 07 Dec 2016 9:18

Hi Dablu,

is possible in the daily job... but I dont send you the solution (to easy).
But I can send this:

use this system variable to do calculation:
-------------
%%OWDAY
Original scheduling day of the week of the job (1= Sun., 2= Mon., and 0=Sat.).
-------------

;-)

Regards

Post Reply