PowerCenter: Script to Unschedule All Workflows

PowerCenter: Script to Unschedule All Workflows

Posted by: Jeff Kinzer

A technique to unschedule all PowerCenter workflows automatically using MX views and pmcmd.

Overview

Here is a technique that can be used to unschedule workflows in bulk automatically or conditionally. The technique uses the workflow which runs a mapping and calls then a command task. Step 1:
  • A mapping reads repository table REP_WORKFLOWS where column START_TIME is not NULL, the target output is a flat file (CSV) list consisting of FOLDER ID, FOLDER NAME and WORKFLOW NAME.
  • The list built by the mapping will contain the workflows that have a schedule but may not necessarily currently scheduled.
Step 2:
  • This step uses a script with the pmrep command to unschedule any workflows specified in the CSV file.
  • The Command task executes a DOS batch file that "reads" the list of workflows and runs ?pmcmd unscheduleworkflow? for each entry in the list.
  • An alternative to using the mapping to build the workflow list is to create an Informatica query that list all Workflows and use the "execute query" pmrep command to build a list.
Note: Please refer to ReadMe.txt for tips on how to implement this solution.You can download this listing as part of the PowerCenter : Useful Script files bundle.

Features

  • PowerCenter version 9.1 and 9.5

Support

I work in Technology for a U.S. company. I have over 20 years experience working in information technology. I currently work with Informatica PowerCenter and Informatica Data Quality in an SAP, Unix, DB2 environment.