Searching By Attributes
AccuGlobe supports selection of features dependent on attribute criteria. Creating, adding and removing from a selection is covered in this section.
Steps To Select Features By Attributes
- Click on the layer in the legend associated with the features to be selected.
- Click the Select By Attributes button on the SelectionTools toolbar. Alternatively, press F10.
- The Select By Attributes dialog will be displayed.
OR
- Right click over the layer in the legend associated with the features to be selected.
- Click on Select By Attributes.
OR
- Right-click over the layer in the legend associated with the features to be selected.
- Click on Open Attribute Table.
- Click on Tools.
- Click on Selection
- Click on Select By Attributes.
Type Of Selection
AccuGlobe permits several actions when selecting by attributes. These are listed below:
- Create New Selection Set
This creates a new selection set. This will reset the selected status for all features prior to executing the newly defined filters.
- Add To Existing Selection Set
This appends to the current subset of selected features. Further features to be selected will need to meet the newly defined filters.
- Remove From Existing Selection Set
This removes from the current subset of selected features. Further features to be removed will need to meet the newly defined filters.
- Select From Current Selection Set
This will only consider features already inside the selection subset. All those matching the criteria will remain selected.
Using Filters
One or more filters are required to produce a selection. Each filter will act on a single attribute field in the layers data. For example, we may want to select all the "MAIN ST" records in a road centerline file. To do this you would create a filter that would search the field that contains the street name for the value "MAIN ST".
Steps For Adding A Filter
- Click on the Add button
- The New Filter dialog will display.
- Select the field the filter will be applied to. See the Fields section below for more details.
- Optionally, to see all the possible values for the choosen field, click the View checkbox.
- Select the logical operator. This indicates how this filter will interact with other filters. See the Logical Operators section below for more details.
- Select the predicate. This indicates the relationship between the field and value that will be used to determine the selection. See the Predicate section below for more details.
- Optionally check the Not checkbox. This will invert the predicate. For example, if the predicate is set to equals (=), checking the not will make it 'not equal', or (!=).
- Type in the criteria. See the Criteria section below for more details.
- Click the Add button to add the filter.
- Optionally add more filters.
Fields
AccuGlobe lists all available fields that can be used for the selection purposes. Select the field that the search is to be compared against.
Logical Operators
Logical operators define the relationship between filters. For example, if we had two filters, with the first being STREETNAME = "MAIN ST" and the second being STREETNAME = "HIGH ST" and a logical operator of Or on the second filter (the logical operator of the first filter is ignored), the query would select all records where the STREETNAME field was either "MAIN ST" or "HIGH ST". In this example, if the logical operator was changed to And, no features would be selected as it is impossible for the same field to be both "MAIN ST" and "HIGH ST" for a given record. The following logical operators are available in AccuGlobe.
- And
- Or
- XOr (Exclusive Or)
Predicates
The following predicate operators are available in AccuGlobe:
- = (Equals)
In this case the field value must exactly match the criteria in order to be selected.
- Like
This is a wildcard search. Use the % symbol as a wildcard character. For example, setting the predicate to Like, and the criteria to SM% would return all features that had a value beginning with SM for the choosen field.
- < (Less than)
Only appropriate for numeric fields. Selects all features where the value of the choosen field is less than the criteria.
- > (Greater than)
Only appropriate for numeric fields. Selects all features where the value of the choosen field is greater than the criteria.
- <= (Less than or equals to)
Only appropriate for numeric fields. Selects all features where the value of the choosen field is less than or equal to the criteria.
- >= (Greater than or equals to)
Only appropriate for numeric fields. Selects all features where the value of the choosen field is greater than or equal to the criteria.
Criteria
This is the discrete value that the field will be compared against. For value ranges please use multiple filters to create the desired effect.
Please note that it is possible to define a data field as a criteria.
Filters
AccuGlobe lists all the current filters to be used for the selection set. It is possible to add new, edit existing and remove unneeded filters using the corresponding buttons.
Steps For Executing The Query
Once all of the filters have been defined the query needs to be executed.
- Click on the Execute button.
- After the selection query completes, a label in the bottom left corner of the dialog will indicate how many features matched the selection filters.
- Optionally zoom to the selected features by clicking the Zoom To Selected button.
- Optionally save the filters for later use by clicking the Save button. This is useful when you use a complex query over and over again. Saved filters can be loaded by clicking the Load button.
A screenshot of the select by attributes dialog is shown below: