# Select By Location v. Topological Operators

RECALL: ATTRIBUTE QUERY OPERATORS – AND, OR

GIS Data Layer:

• LayerName: PlayingCards
• Description: There are 52 polygons; each polygon has one record in the attribute table
• Fields in the attribute table:
• SUITE: club, spade, heart, diamond
• COLOR: red, black
• FACECARD: yes, no
• VALUE: 1 – 13 (ace = 1, J = 11, Q = 12, K = 13)

SAMPLE QUERIES:

‘VALUE’ = 7

‘SUITE’ = “heart”

‘VALUE’ = 7 OR ‘SUITE’ = “heart”

‘VALUE’ = 7 AND ‘SUITE’ = “heart”

SELECT BY LOCATION

Now, instead of selecting by an attribute value, an Attribute Query, lets select cards based on a dice roll – specifically, where it lands.

Consider the figure above where the die landed on the five-of-spades.  Common questions addressed by SELECT BY LOCATION are:

• what card(s) did the dice land on (intersect)
• what card(s) are near the dice (within a distance)

Select by location (relationship = intersect)

The die intersects (passes over or lies across) the five-of-spades.

Select by location (relationship = within a distance)

The 4, 5, an 6 of hearts, diamonds, and spades are all within a (1 card) distance of the dice.

What if we had many dice?