Skip to main content

In a file geodatabase, I have created over 400 feature classes. To each feature class, attributes will be added. Therefore I have created a workbench in which several tables are joined. An intermediate result is a table which contains a field called ‘Attribuut’. This column contains the names of all the target attributes, each row one attribute. This intermediate table also contains a field (‘Gegevenstype’) which describes how the future attribute is defined (field type). A simple ‘Attribute creator’ transformer does not do the job. I have read and tried several possible solutions on the FME-forum, but unfortunately without result. To understand how the process works, a tester is added to create a table for one specific feature class. When the process functions properly, a loop will be added to perform the job for all objecttypes.

Can anyone help???

Not sure I understand what you want to achieve exactly, but...

Generally speaking you can create a column from an attribute by just selecting the Attribute Value:

Then you can you can use an Aggregator to merge all the features with the same Id:

The tricky bit is that in the DataInspector, the columns are there, but are not exposed:

This is because the schema is dynamic. It was created it on the fly and it can differ from feature to feature.

What you have to do next depends on what you want / need.

- If the datamodel already exists and you only need to insert the features, connect to the file geodatabase and insert them. Unexposed attributes will be filled as well.

- If the datamodel does not exist you might want to create it at first, then fill it.

Added template to play with.

rowstocolumns2019.fmwt


@pzwaag

 

Hi P.

 

Basically you have a schema defintion.

All you need to do is create it. (or use it on a dynamic wrtiter).

 

You can just change the names of the fields to fme naming convention for this.

And at write time (dynamical) refer to it.

 

 

There are a lot of examples of this ont this forum.

Try "dynamic schema" as searchkey on this forum.


Hi @pzwaag,

I agree with @gio, you want to use a dynamic writer possibly with an external schema added as a workspace resource or via a schema reader (https://knowledge.safe.com/articles/1046/dynamic-workflow-tutorial-destination-schema-is-de-1.html )

Succes!

Itay


Thank you for your answers! You have given me the right direction. Now I am able to create feature classes with each their own attributes. Still a lot of work to do, but at least I know it is possible. !


You could also use the AttributePivoter transformer to create dynamic attributes from an attribute value.

See the GroupCoumnsBy parameter

http://docs.safe.com/fme/html/FME_Desktop_Documentation/FME_Transformers/Transformers/attributepivoter.htm


Reply