Skip to main content
Solved

How to delete geometries in a layer, so that only one is left?

  • February 20, 2023
  • 2 replies
  • 26 views

Forum|alt.badge.img

I have one feature, which has two geometry points with text location. I only need one of them. Is there a possibility in FME to delete every geometry, except one?

image

Best answer by ebygomm

You can also use a GeometryPartExtractor to just keep the first part (index starts at 1 so 1 is part 0 in your screenshot)

In the advanced editor

number(/geometry/geometry[1]/@fme_id)

 

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3427 replies
  • Best Answer
  • February 20, 2023

You can also use a GeometryPartExtractor to just keep the first part (index starts at 1 so 1 is part 0 in your screenshot)

In the advanced editor

number(/geometry/geometry[1]/@fme_id)

 


david_r
Celebrity
  • 8392 replies
  • February 20, 2023

You could try a Deaggregator followed by a Tester checking for _part_number = 0.