QGIS – Handling Rendered NULL Values in Joined CSV Files

attribute-joinspolygonqgisshapefilesymbology

I have a set of polygons in a single shapefile layer. I have added a data table as a new layer and joined the two layers. Some of my polygons do not have entries in the data layer and consequently, they are not rendered at all.

I could of course add entries to my data table, but is there a way I can show these missing polygons?

missing polygons

In the image there are many missing polygons in the larger white spaces.

Here is the join between the data and the layer.

join

and here is the symbology:

symbology

There are many missing polygons in the larger white areas (the ones with the blue dots are a few examples). This image shows some of the missing ones that appear if I turn the Graduated Symbology off. I am sure the reason is that my shapefile layer is linked to a text layer that does not have entries for all the polygons. So they are NULL I guess rather than 0. What I need is the ability to show the polygons with no data.

missing polygons

Best Answer

Solution 1

Use Categorized instead of Graduated layer rendering style, set you attribute field Compton1_Nonconformists as input for Value and click Classify. For every value contained in this field, you will get a separate color + another one for all other values, thus including NULL.

Solution 2

If you do not have fixed values, but stepless values with no two identical ones, stick to your initial solution, but duplicate the layer and apply a style for only the polygons with NULL values.

Solution 1: Polygons with value = NULL are contained in the category all other values, thus blue: enter image description here