Using the Exceptions table


The Exceptions table contains exceptions by which you can specify a utility process that you wish to force or exclude for an object or wildcard group of objects. You can specify WHERE clause conditions to limit exceptions (for example, to a specified time frame, job name, or submitter).

A common use of exceptions is to permanently prevent processing, or to temporarily force or prevent processing. BMC AMI Utility Manager always reads exception records from most specific to least specific and honors the first one it finds.  

Important

Be sure to delete temporary records after their time frame has passed to prevent BMC AMI Utility Manager from considering them again.


Example

You are changing the structure of a table on a Sunday between 6:00 A.M. and 9:00 A.M. and want to exclude it from a reorganization at that time without having to change or skip the job schedule. To exclude this table from reorganization, specify the following exception record:

TYPE                    TS
NAME                    DB001.TRANSACT
PARTITION               0
REORG                   X
COPY                    I
STATS                   I
REORG_WHERE             WHERE CURRENT_TIMESTAMP BETWEEN ‘2018-04-08-06.00.00.000000’ AND ‘2018-04-08-09.00.00.000000’             

This exception record specifies that the DB001.TRANSACT table space is excluded from a reorganization between 6:00 A.M. and 9:00 A.M. on a Sunday, 8 April, 2018.

The WHERE clause uses an IBM Db2 function to specify a time frame. 

Example

The following statement uses a Db2 scalar function to force or exclude on Sunday or Saturday:   

WHERE DAYOFWEEK(CURRENT_DATE) IN (1,7)
Example

The following statement uses an BMC AMI Utility Manager global column to force or exclude processing if the job name starts with PAYR:

WHERE G.JOBNAME LIKE ‘PAYR%’

For a list of BMC AMI Utility Manager global columns, see Exceptions-table.

Activating and deactivating exceptions

The ACTIVE column setting in the Exceptions table enables you to activate or deactivate an exception without deleting it. You can use this setting to deactivate an exception, but keep it for future use. For example, if you encounter a problem running a reorganization because of an object, you might create an exception in the Exceptions table to exclude the object. If you resolve the problem, you might want to deactivate the exception but not delete it in case the problem recurs.

The following ACTIVE column settings are available:

  • Y—BMC AMI Utility Managerprocesses the exception normally.
  • N—BMC AMI Utility Manager ignores the exception.

Setting exceptions to expire

You can set an exception to expire based on the following criteria:

  • Date and time
  • Number of runs per job step

Setting exceptions based on date and time

To set an exception to expire based on date and time, enter a timestamp in the EXPIRATION_DATE column in the Exceptions table. When the specified date and time arrives (to the nearest second):

  • BMC AMI Utility Manager sets the ACTIVE column value to N.
  • The exception remains in the table for future use.

Setting exceptions based on the number of runs per job step

To set an exception to expire based on the number of runs per job step, enter an integer in the EXPIRATION_COUNTER column in the Exceptions table. This integer represents the number of times the exception can run per job step. If the EXPIRATION_COUNTER column value reaches 0, indicating that the exception has expired, BMC AMI Utility Manager sets the ACTIVE column value to N. A column value of -1 or lower indicates that the column is not in use.

If you set an EXCEPTION_COUNTER column value, the value decreases by 1 in the following cases:

  • You use a wildcard and multiple objects activate the same exception.
  • Multiple RTS syntaxes are stacked in the job step.

Additional considerations

  • If you set an exception to expire using both the EXPIRATION_DATE and EXPIRATION_COUNTER columns, the exception expires when the first expiration condition occurs. 
  • If you set the ACTIVE column value to Y when an exception has expired, BMC AMI Utility Manager ignores your setting and treats that column value as N.
  • If you do not set an ACTIVE, EXPIRATION_DATE, or EXPIRATION_COUNTER column value, BMC AMI Utility Manager
  • If you enter unauthorized values, BMC AMI Utility Manager ignores them and treats the exception as active.
  • BMC AMI Utility Manager does not save ACTIVE, EXPIRATION_DATE, and EXPIRATION_COUNTER column values if you use the REPORTONLY or REPORTALL keyword. 

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*