Rule Builder > Queries and Facilities > Query Examples > Monorule Query

This kind of query is the simplest type containing only one rule. This type of query requires only the Query plug-in installed.

  1. Launch the Rule Builder in Developer mode.
  2. Click Options on the File menu to open the Options dialog box. Install the Query plug-in, uninstall the Facility Explorer plug-in, and click the OK button.
  3. Select <InstallDir>/doc/docreferences/usrbuilder/data/QueryRepository to open the Query Repository as shown in Figure 17.18.

  4. images/openRepository1.png
  5. Figure 17.18    Open Repository Dialog Box
  6. Click Query Editor on the View>Query Panels menu or click the images/queryEditor_buttona.png button to open the Query Editor.
  7. Click the images/addquery_icona.png button in the Query Editor to add a new query. The query is given the name Rule Query and added to the drop-down list. The name is incremented each time you create a new query, for example, Rule Query_2...
  8. Write the following rule query:
  9.        For each business rule
                such that priority is high
           
           Do
                Insert as query result
    

Your query should look like Figure 17.19.

images/query_panel1.png

Figure 17.19    Monorule Query Example
  1. Click the images/executequery_icona.png button to execute the query. Four elements should be found and displayed in the Query Results panel as shown in Figure 17.20.

  2. images/query_example1.png
  3. Figure 17.20    Monorule Query Results

Customer Support | Copyright © 1987-2004 ILOG S.A. All rights reserved. Legal terms. PREVIOUS   NEXT