Creating and Executing Jobs that Include Filter Queries

This section discusses how filter queries affect:

  • Job Creation

  • Job Execution

Job Creation

At the time of job creation, Filter Query steps can be filtered by any of the standard attributes (such as Platforms) as is the case for any other Step type. The filtering of a Filter Query step in this manner does not invalidate or cause steps that reference the filter query to filtered.

At job creation all Filter Queries defined within the template will be set to a default value of Null or No Value. No Step will be filtered by an Ad-Hoc Filter Query at job creation, because no Filter queries have been run at that time. The earliest these Filter Queries can be executed is in the first step of the template/job.

Job Execution

On Filter Query step execution, results are retrieved for all filter query ID’s defined within that specific Filter Query step. These results are written to the Change Assistant database.

  • The execution accounts for the orientation of the Filter Query step.

  • The return values for each Filter Query are noted in the CA log listing the Filter Identifier, Filter ID, the Hide if True Condition, the return value and whether the Hide if True Condition was met.

  • In the event of a SQL error, an error message is written to the CA log and the step is marked as Failed.

  • In the event that the SQL returns a value of the wrong type (numeric as string) ,an error message is written to the CA log and the step is marked as Failed.

Upon completion of this execution, the template is refreshed and as part of this action filtering of steps will occur. Filtering of steps by filter query can only occur where all associated Filter Identifier’s have been resolved and are not in the Null or no value state. This is true even when only a single FALSE is required to filter a step. All the filter query results are also written to a log file. Each filter step generates a log file with results named to match the filter value for example filter0001_out.log.

When a Job is opened or refreshed – the filter query filtering will execute to ensure that all required filtering has occurred. All steps filtered by Filter query are listed in the job.log file.