Spatial Queries#
đź”™Back to Homepage
Manual selection#
In the toolbar, select the
Select Featurestool.Select features individually by clicking on a feature.
To select several features, you can press and hold Ctrl (Cmd on MacOS) and select one feature after the other.
Selected features will be highlighted in bright yellow.
If you open the attribute table, the selected feature will appear in blue.
Example: Manually select countries
Select by Location#
QGIS lets you select features based on their location using the tool
Select by Location.The tool uses spatial queries to select features. These look at the spatial relations between a set of features.
For example two features can intersect, or another feature is fully contained within another, or two features do not touch each other (disjoint).
QGIS uses the following spatial relations: Intersect, Contain, Disjoint, Equal, Touch, Overlap, Are Within, Cross.
Check out the QGIS documentation on spatial relations to learn the differences between each spatial relation.
Example: Select all cities in China (intersect)
Example: Select all neighboring countries of China (touch)
Export Selection#
Once selected, you can further manipulate the features by, for example, exporting them to a new layer:
Right-click on the layer with the selected features ->
Export->Save selected features as..