Solved

FME Writer not exporting all results after GeometryValidator

  • 25 January 2023
  • 4 replies
  • 17 views

Badge

I am trying to simply export results with a Writer into a .shp. If I do not use a GeometryValidator most of the features are present in the final attribute table, but not shown in a ArcGIS map. If I use the GeometryValidator and then use both the good and the repaired features as inputs for the Writer, some results are missing from the final attribute table, but all the result in said table are also displayed in an ArcGIS map. The log gives following warning "Dropping heterogeneous aggregate feature for the SHAPEFILE Writer, due to feature type allowed geometries restriction". How do I solve this? Thank you!

icon

Best answer by rivam 25 January 2023, 14:48

View original

4 replies

Userlevel 4

Try inserting a GeometryFilter before the writer to only include geometry types compatible with the output feature type definition.

In FME versions prior to 2022 you'll need to activate the option "homogenize collections" in the settings.

Userlevel 5
Badge +25

One of the restrictions of shapefiles is that they can only support one type of geometry per file. This also goes for aggregate features. So if you have one aggregate containing of a point and a line FME will split that into two seperate features, going to separate shapefiles, in the writer (so really the GeometryValidator does not come in to play here).

 

If you want to avoid this a quick solution would be to use a Deaggregator before the GeometryValidator, although depending on what you want to do you may need to rethink your overall approach.

Userlevel 6
Badge +32

Can you share the data as FFS?

Badge

Found the answer! For some reason the very GeometryValidator was creating some repaired hidden non-polygon features. These are not shown in any result table, but putting the GeometryFilter right after the GeomertyValidator did the trick for me. Putting it at a later stage was not useful, only right after the "repaired" feature coming out of the GeometryValidator. Thank you all for your help!

Reply