Skip to main content
Solved

How to properly set up the FeatureWriter to dynamic and avoid exporting feature with empty or '<missing>' attributes?

  • February 7, 2022
  • 4 replies
  • 218 views

Forum|alt.badge.img

I have a workbench that generates features with about 20 attributes.

Not every run will have the same source and so not every run will fill the 20 attributes in the feature writer.

I have used the NullAttributeMapper just before the FeatureWriter to map null and empty attributes to missing, but it still outputs all the <missing> attributes. I have tried both Automatic and Dynamic, but same result.

What's the best way to only output the attributes that aren't all 'missing'?

 

featurewriter 

 

Best answer by markatsafe

@ts_84​ In FME 2021.2 or FME 2022 betas we've introduced SchemaScanner. This has an option to ignore <missing> attributes when it generates the schema feature. You can then use the schema feature in your dynamic writer

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.

4 replies

Forum|alt.badge.img+2
  • 1891 replies
  • Best Answer
  • February 8, 2022

@ts_84​ In FME 2021.2 or FME 2022 betas we've introduced SchemaScanner. This has an option to ignore <missing> attributes when it generates the schema feature. You can then use the schema feature in your dynamic writer


Forum|alt.badge.img
  • Author
  • 21 replies
  • February 9, 2022

@ts_84​ In FME 2021.2 or FME 2022 betas we've introduced SchemaScanner. This has an option to ignore <missing> attributes when it generates the schema feature. You can then use the schema feature in your dynamic writer

Thank you, that sounds perfect. How do you set up the <missing> parameter in SchemaScanner?

I can't find the Schema Feature in the dynamic writer, is it through Schema definition name?

 

missing f-writer 


Forum|alt.badge.img+2
  • 1891 replies
  • February 9, 2022

@ts_84​ Have a look at the SchemaScanner demos we recorded here


Forum|alt.badge.img
  • Author
  • 21 replies
  • February 22, 2022

@ts_84​ Have a look at the SchemaScanner demos we recorded here

The SchemaScanner is perfect thank you. It works really well with Shapefiles.

I tried with Geopackage and it's not handling it quite well for some reason. Without the SchemaScanner it's ok.

Problem with fme_feature_type. I think it's missing proper id or something like that to build the Geopackage.