TransWikia.com

Conditional value maps in a comboBox using QGIS

Geographic Information Systems Asked on December 13, 2020

I’m using a layer which has some attributes. The first attribute (lets say "Country", for example) has a comboBox and the user can freely choose which value he wants (For example, any country in North America). The second comboBox (lets say "Cities", for example), will display only the values which are related to the first attribute (only cities of the corresponded country). So, the values of the second comboBox will be somehow related to the first comboBox (not displaying cities which does not belong to the selected country). I followed the following website and I was able to do it as I wanted (using value relation): https://north-road.com/drill-down-cascading-forms/.

However, I had to create a whole new layer only for the sake of mapping "Countries" with its "Cities". Is there a way of doing it, without having to create a whole new layer only for mapping the values? Could I do it only using filters or something like this? (This will be useful for me, because I’m gonna have a special case, when I will have to map a very few values conditionally)

In the end, I would have something like this:
enter image description here

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP