Skip to main content

I have two polygons which overlaps and I use transformers to have the intersection (I tried Clipper, AreaOnareaoverlayer, spatialrelator and intersection) . So, it created a new polygon (the overlap of the two polygon.) The problem is that this new polygon belongs (in the attribute table) to one of the two polygon (The feature name of the new polygon is the name of one of the polygon) but I would like the name of the both polygon even if it created two overlap (the same but one with the name of the first polygon and one witch the second).

 

Thanks you

 

You're on the right track with the AreaOnAreaOverlayer. In this transformer, create a list on the attribute that contains the polygon name. This will add the names of all overlapping polygons to the list. Next, use a ListConcatenator to write all these names back to the attribute that contains the polygon name.

Overlapping_Polygons_with_names


Thanks but it doesn't work even if I did what you did...I had to use "clipper" after "areaOnareaOverlayer" because the two polygons I want to intersect are in two diferent layer... With only areaOnareaOverlayer I only have missing attributes... So, to do what you did I tried with AreaOverArea only, then with Clipper after AreaonArea and with CLipper and after, listBuilder (and then, list sorter and list concatenator) but nothing works...


ListBuilder should not be necessary. Also there should be no need for Clipper just because the polygons are on two different layers, as AreaOnAreaOverlayer will combine the features from both layers.

However there may be a problem when the different layers have a different attribute for the polygon name, so you would have to rename the name attribute on one of the layers.

Overlapping_Polygons_with_names_2


ListBuilder should not be necessary. Also there should be no need for Clipper just because the polygons are on two different layers, as AreaOnAreaOverlayer will combine the features from both layers.

However there may be a problem when the different layers have a different attribute for the polygon name, so you would have to rename the name attribute on one of the layers.

Overlapping_Polygons_with_names_2

Oh thank you! But, I have the two names in the same case (as you have) , and I want in two separate case (features). Your first and third lines represent the part of the squares that don't overlap.

I tried with "AttributeExposer" but it only divides the two polygons in two attributes (not by comma), but I would like two features. For example (screen) (I would like the first or the second table. Thanks !

Example_overlaps


Forgive me, apparently I misunderstood your question. Depending on your exact needs you can use an AreaOnAreaOverlayer or a SpatialRelator. In both cases set Attribute Accumulation to Merge Attributes.

Objects_in_Cities


Forgive me, apparently I misunderstood your question. Depending on your exact needs you can use an AreaOnAreaOverlayer or a SpatialRelator. In both cases set Attribute Accumulation to Merge Attributes.

Objects_in_Cities

Ohh no your polygons were good ! (Two polygons which overlaps) and that correspond to the tables I sent you. I want that the intersection between the two polygons appears twice, once with the name of the first polygon et once with the name of the second polygon (as you seen in my table). Imagine that a city is in two areas (object). I want a feature which tell us that the city1 is in a area and another feature which tell us that the city1 is the second area too. For now, I only have the feature city1 that appears once with the name of an only area.

Sorry It's complicated because my english is bad


So, something like this?

Overlapping_Polygons_and_CitiesIf not, can you provide some sample data (or mock-up data) of cities and objects (areas)?


Reply