Attribute Query (Boolean Selection)

From wiki.gis.com
(Redirected from Attribute query)
Jump to: navigation, search

An attribute query is the process of searching and retrieving records of features in a database based on desired attribute values. [1] See Also Query. Such queries are a fundamental part of managing and analyzing GIS data. Typically, this is performed using a criteria-based query language, most commonly SQL.

In most cases, the desired information can be given as a set of criteria based on the available attributes, such as "having a code of 'CURRENT'." These criteria are formatted in the appropriate query language as a Boolean expression, which can be validated as either true or false for each record in the database. Individual criteria can be constructed and combined using logical operators such as comparisons (>, <, =, >=, <=), Boolean algebra (and, or, not), and functions (sin, cos, sqrt, etc.). An alternative to using attribute query is to perform a spatial selection.

Select.attributes.jpg

Select by Attributes in ArcGIS

In ArcGIS, the 'Select by Attributes' window provides a quick way to build a SQL query to create a selection based on map attributes. In the screenshot below, a simple SQL query has been built that queries the underlying 'POP' (population) attribute record of a layer containing information about US cities (citiesx020 in the example). After executing the query, only those cities having a population greater than 100000 will be selected in the map.

GIS&T Body of Knowledge Concept

Attribute queries fall under section AM2-2 of the 2006 GIS&T Body of Knowledge.

See also


References

  1. http://support.esri.com/en/knowledgebase/GISDictionary/term/attribute%20query Kennedy, Michael. Introducing Geographic Information Systems with ArcGIS