Siebel Business Process Framework: Workflow Guide > Administering Workflow Policies > About Workflow Policy Administration >

Batch Processing Workflow Policies


This topic describes how to configure workflow policies to execute in batch mode.

Creating Batch Policies

You can create workflow policies as batch policies by checking the Batch check box in the Policies applet. When you start workflow monitor in batch mode, it checks for policies with the Batch check box marked. Each policy causes an SQL statement to be issued to identify the specific records that meet the policy conditions. The records identified are then processed in turn and the appropriate actions are carried out.

You can use the batch feature to consolidate email messages for a designated recipient by checking the Batch field in the Actions applet in the Workflow Policies view.

If you consolidate email messages, the recipient receives one email with the information of multiple actions rather than multiple emails. For example, you can create a workflow policy that sends an email to the director of sales each time a quote is submitted with a discount over 30%. If 20 sales representatives submit quotes with the 30% discount and the Batch field is checked, the director of sales receives one email listing the 20 quotes. If the Batch field is not checked, the director of sales receives 20 email messages.

NOTE:  When creating a batch type workflow policy, the comparison operators IS ADDED, IS UPDATED, or IS DELETED must be used in conjunction with regular conditions. These comparison operators are considered special conditions intended for Dynamic mode when triggering rows to look up regular conditions.

Running a Workflow Policy in Batch Mode

The ability to run a Workflow Policy in batch mode allows you to evaluate more data in the database, not just the records that triggered the Workflow Policy. This feature is useful when defining a new policy that needs to be applied to historical data and for enforcing policies that have date conditions.

To run a Workflow Policy in batch mode

  1. In the Workflow Policies view, set the Batch field on the workflow policy to True by checking the Batch check box in the Actions applet.
  2. Associate the workflow policy with a workflow group that is used only for batch processing, using the control on the Group field.
  3. When starting the workflow monitor and workflow action server components, specify the appropriate group name and set the parameter Process the batch policies to TRUE.

Using Batch Mode to Make Sure a Workflow Policy is Triggered Correctly

Consider the following example that demonstrates why previously existing records that meet the workflow policy conditions do not trigger the workflow policy:

Table 75. Example of Records That Meet a Policy But Do not Trigger the Policy
Field
Value

Workflow Policy Name

Account Active

Workflow Object

Account

Group

Test

A workflow policy based on a business object is created to monitor a field when:

  • Workflow Condition, Account Status is Active.
  • Workflow Action, Action: Send Email to Employee.
  • Remove and generate triggers, then start a workflow monitor task for the workflow group Test.

Considerations you should weigh include:

  • New Account records that are added which meet these conditions trigger the workflow policy.
  • Existing Account records that are updated to meet the conditions also trigger the workflow policy.

NOTE:  Account records that previously existed in the database before the workflow policy was created but also meet the workflow policy conditions do not trigger the workflow policy.

If triggers have been generated for this workflow policy, workflow monitor agent evaluates records only if they are updated, or if a new record is created. Therefore, old records are not affected.

To evaluate account records including those created prior to the creation of the workflow policy rule, make sure the workflow policy has the Batch flag checked and the workflow monitor agent is run with Batch Mode set to TRUE.

Siebel Business Process Framework: Workflow Guide Copyright © 2008, Oracle. All rights reserved.