1

Layer A contains terrains knowing that the geometries have been merged when they are contiguous 'and' the owners are identical. The layer includes a variable indicating the number of slots. enter image description here

enter image description here

Layer B contains the lands and a variable indicating the type of owner (the lands are not merged as in layer A).

enter image description here

I am displaying layer B with only owner type 'FF'.

enter image description here

I seek to recover in layer A, the number of corresponding housing. (Here 8 et 26 uniquely)

enter image description here

If polygon FF of layer B contains 1 terrain, there will be a label.

If polygon FF of layer B contains several contiguous terrains, there will be more identical labels (I will then see how to retain only one).

I tried without success to apply a display rule in the labels of layer B:

CASE WHEN owner = 'FF' and intersects($geometry, geometry(get_feature('Layer_A','nlogh', nlogh))) THEN nlogh END

I don't know how to retrieve the values

fcka
  • 923
  • 4
  • 10
  • 1
    Are you asking how to join attributes by location? – Erik Feb 24 '23 at 11:51
  • This command allows you to select objects by location. However, I want to display for some objects of layer B, the corresponding labels of layer A. There is therefore a question of localization but also of filter without creating a new layer. In addition I specify that I have my diapers are bulky: layer A : 594035 geometry layer B : 1334777 geometry and i want a display instantaneous... – fcka Feb 24 '23 at 13:48
  • Please edit your question accordingly. – Erik Feb 24 '23 at 14:15
  • @Erik It's done – fcka Feb 27 '23 at 16:39
  • How does the geometry for Layer A correspond with Layer B, are the polygons the same, overlapping, ... etc? Perhaps add another screenshot showing Layer A too, it will make your question clearer. – Matt Feb 27 '23 at 17:16
  • @Matt It's done – fcka Feb 28 '23 at 11:19
  • 1
    Does this help? https://gis.stackexchange.com/q/424303/128665 – Matt Mar 01 '23 at 09:28
  • @Matt Thank you this does not answer my problem but it is very interesting. These functions display labels differently depending on the scale. – fcka Mar 01 '23 at 21:42
  • I found a link on the subject https://gis.stackexchange.com/questions/374322/qgis-use-one-layer-to-block-another-layers-labels – fcka Mar 10 '23 at 20:42

0 Answers0