We will do a simple example.

We have added a cadastre map in QGIS and we want to find all cadastre smaller than 130 square meters.

 

To see the data in the cadastre map, just click on the icon "Open Attribute Table".

 

 

A box popups with all the registered data for this layer.

Click on "Select features using an expression". (You can also find this icon right beside "Open Attribute Table" in QGIS main window)

 

 

The box "Select By Expression" popups.

Under "Function List" you can select many different functions.

We will use "Fields and Values".

Click on "+" in front of "Fields and Values".

 

 

We now see all the columns in the database.

Double click on "Vidd_i_mat".

 

 

"Vidd_i_mat" is now appearing in "Expression". This is where we build our formula.

 

 

We write "< 130" after "Vidd_i_mat". Then click "Select".

 

 

And here is our graphical result. What we found is showed in yellow.

 

 

If you like to see the result as a table, just click on "Open Attribute Table", and then choose "Show Selected Features" in the buttom box.

 

We will make another example.

We have added a sewer map.

We want to find all sewers with a length higher than 100 meters with the type PVC.

 

Click on the icon "Select features using an expression", and the box "Select By Expression" popups.

 

 

Click on "+" in front of "Geometry".

 

 

Double click on "$length", and the "$length" variable will appear under "Expression".

 

 

Click on "+" in front of "Operators".

Double click on ">", and this sign will appear under "Expression".

Then write "100" after ">".

Double click on "AND", and this text will appear under "Expression".

 

 

Click on "+" in front of "Fields and Values".

Double click on "tilfar", and this will appear under "Expression".

Click on "Load all unique values". Then all values from the column "tilfar" will appear in a list.

 

 

Click on "PVC", and this text will appear under "Expression".

Our formula is now ready.

Click on "Select", and then on "Close".

 

 

The result of our search is showed graphically with yellow color.

 

If you want to see the result as a table, just click on "Open Attribute Table".

 

 

and then choose "Show Selected Features" in the button box.

 

You are welcome to write comments below. If you have any questions, please post in the forum.

Search in file