Option 1.3. Use a Query as a Range Source

A query can define a range that is included in any criteria you want. The criteria does not have to be locations. It can, for example, be a list of attributes.

Example

A range can be orders for computers with selected top-of-the-line features, that are listed in the TADB database as attributes for a Bill of Materials.

These orders can be identified through a query for those attributes.

The query that includes the range of features can be used as the range source.

Steps to select a range as a source include.

Open the P1 dialog box.

Use P1 dialog box features.

(Optional) Use Expression Browser features.

(If an existing query range is not acceptable) Configure the named query.

  1. Open the P1 dialog box.

Double-click Solve Name in the Set Source Solve function block.

A P1 dialog box opens.

The P1 dialog box provides you with the Browse, add and editing options that other RCO function blocks offer.

  1. Use P1 dialog box features.

Do any of the following through the P1 dialog box.

Option

P1 Dialog Box

Solve Name

Identifies the named query to:

Use in the block.

Be edited if Edit is selected on the popup menu.

Browse buttons

Opens the Expression Browser

Popup Menu button

Displays the popup menu

 

Selections are:

 

New

Opens a New Expression dialog box.

1.   Enter a name for the new query.

2.   Click OK.

Opens the Expression Editor.

 

Edit

Opens the Expression Editor for a query that is entered in the Solve Name field.

 

Browse

Opens the Expression Browser.

 

Recent named queries

Uses the named query that is selected in the list.

OK

Closes the P1 dialog box; displays the named query as the parameter value.

  1. Use Expression Browser features.

If you opened the Expression Browser you can use the same steps to create or edit a query as you would for any query.

  1. Configure the Query range.

  1. Use the Expression Editor syntax to create or edit an expression that will determine what items will be included in the range.

Example

The computer factory has a class of computers called CLASS 1.

The computers have a 19" monitor, ergonomic keyboard and are not blue in color.

A CLASS1 query will select all of the purchase orders that list these attributes.

The selected orders will be the orders in the query range.

  1. Apply the query and close the Expression Editor when the expression is ready.

The Expression Browser opens.

  1. Select the Query.

  2. Click OK.

The P1 dialog box opens with the named query in the Solve Name field.

  1. Click OK.

Result: The named query displays as the value for the Range Name parameter.

More information

RSA function blocks list.

Step 1. Define the Source Range