Skip to main content
Solved

How to save the Attribute definition in a csv ?

  • February 9, 2022
  • 4 replies
  • 74 views

Hi ! I wanted to know if there was a way to save the attributes definition (Name, type and width) in to a CSV.

Thanks for the help !

Best answer by markatsafe

Thanks for the answer ! that's a very straight forward transformer to do what i want, but I only have access to the 2020 version of FME and I can't find the transformer so I guess it's only for the newer versions of the software ?

You can use the Schema (any format) instead, or the FeatureReader <schema> port

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

chrisatsafe
Contributor
Forum|alt.badge.img+2
  • Contributor
  • 606 replies
  • February 9, 2022

Hi @fmenewbie_jr​ ,

 

Check out the new SchemaScanner transformer - it'll tell you everything you need. Here is an example with an Excel file where it provides the name, data type (<width>, <precision if applicable>). A schema feature will store all of this in a list which you can explode with a ListExploder. Then you can parse/format as needed for your desired output.

imageIf you are using an older release of FME, you can still get this information with a schema feature using either the Schema Reader or a schema feature from the FeatureReader.


  • Author
  • 2 replies
  • February 9, 2022

Hi @fmenewbie_jr​ ,

 

Check out the new SchemaScanner transformer - it'll tell you everything you need. Here is an example with an Excel file where it provides the name, data type (<width>, <precision if applicable>). A schema feature will store all of this in a list which you can explode with a ListExploder. Then you can parse/format as needed for your desired output.

imageIf you are using an older release of FME, you can still get this information with a schema feature using either the Schema Reader or a schema feature from the FeatureReader.

Thanks for the answer ! that's a very straight forward transformer to do what i want, but I only have access to the 2020 version of FME and I can't find the transformer so I guess it's only for the newer versions of the software ?


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

Thanks for the answer ! that's a very straight forward transformer to do what i want, but I only have access to the 2020 version of FME and I can't find the transformer so I guess it's only for the newer versions of the software ?

You can use the Schema (any format) instead, or the FeatureReader <schema> port


  • Author
  • 2 replies
  • February 10, 2022

Thanks for the answer ! that's a very straight forward transformer to do what i want, but I only have access to the 2020 version of FME and I can't find the transformer so I guess it's only for the newer versions of the software ?

I combined the two answers and used the FeatureReader with a ListExploder and it worked ! thanks for the help !!