Tuesday, September 11, 2012

Control-M Variables

To set date -x  in control-M  variable to be in DD/MM/YYYY format

%%SET %%PREVDD = -1
%%SET %%YEST = %%$CALCDATE %%$DATE %%PREVDD
%%SET %%YYYY=%%SUBSTR %%YEST 1 4
%%SET %%MM=%%SUBSTR %%YEST 5 2
%%SET %%DD=%%SUBSTR %%YEST 7 2
%%SET %%YESTERDAY=%%DD/%%MM/%%YYYY

This will give today's date in DD/MM/YYYY format
%%SET %%TODAY = %%DAY/%%MONTH/%%$YEAR

For more default variable click here.

1 comment:

Unknown said...


Ecorptrainings.com provides CONTROL-m in hyderabad with best faculties on real time projects. We give the best online trainingamong the CONTROL-m in Hyderabad.
Classroom Training in Hyderabad India