Previous Topic

Next Topic

Book Contents

Book Index

ctmorder examples

The following are examples of ctmorder utility:

The following command orders jobs named acct_job contained in SMART Folder ACCT100. Any jobs placed in the Active Jobs database will have the current Control‑M date as their original scheduling date:

ctmorder -FOLDER ACCT100 -NAME acct_job -ODATE odat

The same results can be achieved using the -input_file parameter as follows:

ctmorder -input_file ~<controlm_run_as name>/ctm_server/data/ctmorder_acct100.txt

The referenced file contains the following lines:

-FOLDER ACCT100

-NAME acct_job

-ODATE odat

The following command orders all jobs contained in the SMART Folder ACCT100 whose job name begins with ga. Any jobs placed in the Active Jobs database will have the date March 15, 2016 as their original scheduling date:

ctmorder -FOLDER ACCT100 -NAME "ga*" \
-ODATE 20160315 -FORCE y

The following command forces all jobs contained in the ACCT100 Sub Folder. Any jobs placed in the Active Jobs database will have the date December 31, 2016 as their original scheduling date:

ctmorder -FOLDER ACCT100 -NAME ACCT101 \
-ODATE 20161231 -FORCE y

The following command forces the third job contained in the SMART Folder ACCT200 whose job name parameter consists of prodyjob. This job is placed in the Active Jobs database and will have the date December 31, 2016 as its original scheduling date. This job is added to a folder whose orderid is B2.

ctmorder -FOLDER ACCT200 -NAME prodyjob \
-ODATE 20161231 -FORCE y -SEQNO 3 -INTO_FOLDER_ORDERID B2

The following command assigns the variable %%PRDNDATE with the value of %%ODATE, and orders every job in the PRODUCTION SMART Folder whose job name has a prefix of PRDN. These jobs are placed in the Active Jobs database in a folder and are assigned the date December 31, 2016 as their original scheduling date.

ctmorder -FOLDER PRODUCTION -NAME "PRDN*" \
-ODATE 20161231 -ORDER y -INTO_FOLDER_ORDERID newt\

-VARIABLE %%PRDNDATE %%ODATE

The following command orders every job in the INVENTORY SMART Folder whose job name has a prefix in the range BIN_A1 to BIN_A9. These jobs are placed in the Active Jobs database in a new SMART Folder, and are assigned December 31, 2016 as their original scheduling date. The APPLICATION and RUN_AS parameters of these jobs are modified to STOCK_COUNT and STOREMAN, respectively.

ctmorder -FOLDER INVENTORY -NAME "BIN_A?" \
-ODATE 20161231 -FORCE n -INTO_FOLDER_ORDERID newt   \
-VARIABLE %%PRDNDATE %%ODATE  \
-VARIABLE %%APPLIC STOCK_COUNT  \
-VARIABLE %%RUN_AS STOREMAN

Parent Topic

ctmorder