Refine Query Technique

It is recommended that you define a query for a task, typically as a search specification in a task view step. However, sometimes it is not possible to know at design time the exact search specification that the user requires at run time, and Siebel CRM might display a large number of records when the search specification for the task runs. You can configure a task that uses query-by-example to allow the user to refine this query.

Siebel CRM uses the following logic in the refine query technique:

  1. The task view step includes a broad search specification.

  2. The Task UI framework sets this search specification as an anonymous search specification on the business component, using the & (ampersand) prefix to substitute task properties that the search specification references.

  3. The task view includes a Refine Query button that calls the Refine Query method on the business component. This method uses the search specification set in Step 1 but allows the user to refine the search criteria.

  4. The user refines the search specification, clicks Execute Query in the task view, and then Siebel CRM displays the task only in query mode.

  5. Siebel CRM uses the refined search specification set in Step 3 to run the query.

    If Siebel CRM does not display the fields that the search specification in Step 1 references, then the user cannot remove this query even if the user is required to remove it.

Example of the Refine Query Technique

The predefined Create Order task includes a task view step that allows the user to choose a number of products. To search products, the user can use the customer zip code, but this query can return hundreds of products. The Create Order task allows the user to use the name to refine the query. For example:

[Name] LIKE '*300 minutes*'

This task does not display the zip code, so the user can only narrow the original search specification and cannot broaden it. The predefined Create Order task resides in the Siebel Communications application.