
QGIS 2 Cookbook
By :

When investigating a new dataset, it is very helpful to have a way to quickly check which values a column contains. In this recipe, we will use different approaches using both the GUI and the Python console to list the unique values of POI classes in our sample POI dataset.
To follow this recipe, please load poi_names_wake.shp
.
If you are simply looking for a solution based on the GUI, the List unique values tool is available both in Vector | Analysis Tools as well as in the Processing Toolbox menu. You can use either one of these to get a list of the unique values in a column. Having this tool available in the Processing Toolbox menu makes it possible to include it in processing models and, thus, automate the process. The following steps to list unique values use the Processing Toolbox menu:
Start List unique values from the Processing Toolbox menu.
Select the poi_names_wake
layer as Input layer and the class
attribute as Target field...
Change the font size
Change margin width
Change background colour