Creating and running queries
Create queries to retrieve records in a user database. You can create a query for any record type that is defined in HCL Compass Web.
About this task
Creating the query involves several steps: selecting the record type, adding the filters and defining their properties, moving and grouping filters, formatting the results set, and saving and running the query.
Selecting the record type
Procedure
What to do next
Adding filters and defining their properties
Procedure
Moving filters
Procedure
- Select the filter, right-click to display the pop-up menu and click Cut or Copy to either remove it from the current location or copy it to a new location.
- Select the new location, right-click to display the pop-up menu and click Paste to move it to the new location.
Grouping filters
About this task
Procedure
- At the top of the Filters pane, click AND or OR.
- In the Fields pane, click the right arrow to add fields under the AND or OR groups in the Filters pane.
- You can add logical operators only as the root or children of another operator.
What to do next
Note: You can change or delete the existing operator within
the Filter pane. Select the operator, right-click to display the pop-up
menu and click the operator or Delete to remove
it.
Formatting the results set
Procedure
- In the Fields pane, select the field to add from the list and click the right arrow next to the Query Presentation pane to create the columns displayed in the result set.
- In the Query Presentation pane, you can change the default
properties and format for the fields.
- To change the display order of a field, click the up arrow or down arrow to change the display order of a field.
- To change the title of a field, click on the title name in the title column and type the new name.
- To change the sort order of all the fields for a column, click on the column title and the arrow shows the sort order as either ascending or descending.
- To show and sort the fields, select the Show check box. Clearing this check box still sorts the item, but does not display the item.
- To configure the properties of a column for a field, select a sort type from the Sort list (No Sort, Ascending, or Descending), and select a sort order from the Sort Order list sorting indicated by a number from 0 to the total number of display fields minus one.
- To remove a field from the Query Presentation pane, select the field and click the left arrow.
- Optional: To use this display layout as the default format for all new queries based on this record type, select the Use this display layout as the default for new queries check box.