Query

Query icon

 

Use the Query icon from the toolbar to access this function or use the shortcut key "F12."

Use the Query function as a quick inquiry tool to select specific data segments from the database.  You can use the selection criteria fields to define the database inquiry more exclusively, including fields, relationships, values, and data sorts.

In Costpoint web, you can use Query to subquery data on a child result set.  [This functionality replaces the equivalent Subquery pushbutton in Costpoint client/server.]  You can also access Query from Lookups.

Note: There is no Find function in Costpoint web (as there is in client/server).

You must first have selected an application before you can select the Query icon from the toolbar.

Selection Criteria

Field

The fields available for selection for the application display in the drop-down box.  Choose the field you want to use as a selection criterion.

Relation

Use this drop-down box to define a relationship between the data in the Field and Value fields.  The relations available include the following choices:

Is Equal to (=)

Is Greater than (>)

Is Greater than or equal (>=)

Is Less than (<)

Is Less than or equal (<=)

Is Not Equal (!=)

Is Blank (is null)

Is Not Blank (is not null)

Begins With (Like%)

Ends With (Like%)

Contains (Like%)

Value

Use the Value field with the Field and Relation fields to define the rows to be selected from the database.  Enter the specific data or value to which you want to limit your search.

Combine Method

Use either of these radio buttons to make more complex selection criteria statements.

First, select the data for the Field, Relation, and Value fields.

Then select the Add pushbutton.  You will see that your new statement displays in the Query Conditions list box.  

Next, change the information in the Field, Relation, and Value fields, as applicable, to reflect the second (or next) portion of the statement.  Select either the And or Or radio button.

Use the Add pushbutton to add the new statement to the Query Conditions list box.  

Sort By

The fields available for selection for the application display in the drop-down box.  Choose the one field on which the result set should be sorted.  

Then select either the Ascending or Descending radio button.

Your radio button selection will affect the order in which the rows of the result set display in the table window or, as applicable, the order in which the records are accessed in Form View when using the First, Previous, Next, and Last toolbar buttons.

Query Conditions

This list box displays the statements as you create them.  The highlighted row shows the statement that you will modify if you select the Replace pushbutton or that you will remove if you select the Delete pushbutton.

Add

Use this pushbutton to display your selection statements in the Query Conditions list box.

You can also create more complex statements with the Add pushbutton.

Example:  If you want to retrieve records in which the account is greater than "02000" but less than "05000," you would first create the statement:

"Account Is Greater than 02000"

Select the And radio button in the Combine Method group box.

Select the Add pushbutton.

Then change the information in the Relation and Value fields to create the statement:

"Account Is Less than 05000"

Select the Add pushbutton.

The following statement will display in the Query Conditions list box:

WHERE Account > '02000'

AND Account < '05000'

This Query example specifies that the system should sort the records by account, in ascending order.

Replace

Use this pushbutton to modify a previous selection statement that already displays in the Query Conditions list box.

Once you have selected the revised data for the Field, Relation, and Value fields and the Combine Method radio button group box, as applicable, use this pushbutton to enter the statement into the Query Conditions list box. The system will automatically replace the formerly highlighted statement in the Query Conditions list box with your modified statement to reflect the new selection.

Delete

Use this pushbutton to remove the highlighted statement from the Query Conditions list box.

Count

Select this pushbutton if you want to know how many database records satisfy the current selection criteria before you use the Submit Query pushbutton.  The system displays the number of eligible records that meet your criteria in the Query Count field.

Query Count

The system displays the number of eligible records that meet your criteria in this non-editable field.

Ignore Case

Select this checkbox if you want the search to ignore upper and lower case matches for string fields.  In this circumstance, all occurrences of the search value will be selected, regardless of case.  

Submit Query

Select this pushbutton when you are satisfied with your selection criteria and want to perform the database query. The system uses the statements from the Query Conditions list box to retrieve the defined rows from the result set.  

Refresh Form

Select this pushbutton to remove all the current selection criteria from the Query Conditions list box and to clear the previous result set from memory.  

Close Query

Select this pushbutton to close the Query window.  

Top of Page