Querying Data
Click here to download the data that the author used for the course lesson. By downloading the data you will be able to follow the steps completely.
|
The video and printable version of the lesson is provided to assist you in the learning of the material. As always the website will be most up to date component and if there is any difference always use those on the website instead of those in the video or printable version.
Introduction
The purpose of this technical skills lesson is to learn the techniques required to select data by using a query. A query is a database function and a GIS map is a visual database with geospatial references. The learner will need to understand basic logic. For example, what is the difference between an 'AND' and 'OR' in a logic statement?
The logical AND statement requires that both items be true to get visual result and a logical OR statement that requires at least a single member of the group to be true to get a visual result. There are other logic statements that may be used as well as simple mathematical relationships.
For mapping the query outcomes are shown as a visual result, since in general this is when an item is displayed on a map.
AND Truth Table
The logical AND statement requires that both items be true to get visual result and a logical OR statement that requires at least a single member of the group to be true to get a visual result. There are other logic statements that may be used as well as simple mathematical relationships.
For mapping the query outcomes are shown as a visual result, since in general this is when an item is displayed on a map.
AND Truth Table
OR Truth Table
Mathematical operations such as greater than, less than, greater than or equal, less than or equal within the expressions will also be used in querying data.
The formatting of the query can have no variation and it is suggested that query builder be used instead of writing the express manually. One attribute can be displayed and the use of a query to a different attribute to can show different interrelationships. Complex queries can also be written which use multiple logical and mathematical functions, as long as the components are in the same shapefile. Mathematical order of operations are used in the process of a query.
The formatting of the query can have no variation and it is suggested that query builder be used instead of writing the express manually. One attribute can be displayed and the use of a query to a different attribute to can show different interrelationships. Complex queries can also be written which use multiple logical and mathematical functions, as long as the components are in the same shapefile. Mathematical order of operations are used in the process of a query.
Data Requirements
A shapefile that contains data such as population, median income, age and race at the census tract level is required to successfully complete this lesson.
https://drive.google.com/open?id=1YBpN7YTzxp06rR4wexv8oKmDnd8K0Ghi
https://drive.google.com/open?id=1YBpN7YTzxp06rR4wexv8oKmDnd8K0Ghi
Prerequisite
The learner should have experience with placing data on to a map, the ability to perform tabular joins and merging shape files (optional).