Skip to main content

Hi,

I'm using FME Desktop 2017 to write features to a feature class in a geodatabase using a dynamic schema definition. The dynamic schema is necessary as I'm using an AttributePivoter transformer. When I selected "Dynamic Schema Definition" in the Feature Type Parameters, FME automatically changed the Feature Class name to the attribute "fme_feature_type". Whenever I try to change anything about this, my workbench doesn't work anymore. Can I change anything about this? It'd be quite useful to assign a name different from fme_feature_type...

Any hint is appreciated ;-)

Hello, @kgt_lena

The most likely reason for the workspace failing after adjusting the Feature Class/Table name is due to naming conflicts(possibly duplicates as an example). The fme_feature_type attribute will write each feature to the feature class that matches the fme_feature_type value. You are able to change the Feature Class/Table name to another attribute other than fme_feature_type.

What error are you receiving when changing the fme_feature_type to a different attribute, would you mind posting the error, please?

 

 

Here is the Dynamic Tutorial that may assist solving the issue: https://knowledge.safe.com/articles/1050/dynamic-workflow-tutorial-introduction.html

Hello, @kgt_lena

The most likely reason for the workspace failing after adjusting the Feature Class/Table name is due to naming conflicts(possibly duplicates as an example). The fme_feature_type attribute will write each feature to the feature class that matches the fme_feature_type value. You are able to change the Feature Class/Table name to another attribute other than fme_feature_type.

What error are you receiving when changing the fme_feature_type to a different attribute, would you mind posting the error, please?

 

 

Here is the Dynamic Tutorial that may assist solving the issue: https://knowledge.safe.com/articles/1050/dynamic-workflow-tutorial-introduction.html
Thanks @trentatsafe! I think I didn't describe my problem properly, sorry - I try to be more specific. What I understand from your answer is that my FeatureClass name must be derived from an attribute value and cannot be assigned by simply typing it in that field "Feature Class or Table Name" in the Writer Parameters.

 

In a further step, I'd like to not only assign a simple string as the FeatureClass name, but even name the output something like "gender_2017", "gender_2016", "gender_2015" and so on. The first part ("gender_") will be static, the year will be depending on user input and is already used in a published parameter. So it'd be no problem to concat these two strings to get the desired FeatureClass name, but until now I just thought I can to this concatenation "on the fly". Instead, I now think I have to create an attribute with this value to use it as my FeatureClass name. Is that correct? Thanks in advance for any further help :-)

 


Thanks @trentatsafe! I think I didn't describe my problem properly, sorry - I try to be more specific. What I understand from your answer is that my FeatureClass name must be derived from an attribute value and cannot be assigned by simply typing it in that field "Feature Class or Table Name" in the Writer Parameters.

 

In a further step, I'd like to not only assign a simple string as the FeatureClass name, but even name the output something like "gender_2017", "gender_2016", "gender_2015" and so on. The first part ("gender_") will be static, the year will be depending on user input and is already used in a published parameter. So it'd be no problem to concat these two strings to get the desired FeatureClass name, but until now I just thought I can to this concatenation "on the fly". Instead, I now think I have to create an attribute with this value to use it as my FeatureClass name. Is that correct? Thanks in advance for any further help :-)

 

Hello @kgt_lena

 

 

I believe your last point is correct. You are able to concatenate your feature names when using a Dynamic writer. You mention wanting to have just the last portion of the feature type change. In your case, Gender_ would be the unchanging part, while the year would change. I don't believe you could use a Parameter as you would need to differentiate the features from one another. However, if you can use an Attribute that would work.

 

 

So if the Year attribute contains 2015, 2016 and 2017 in different features. Your writer feature type name would look like:

 

Gender_@Value(Year).

 

Which would output three different feature types with the names Gender_2015, Gender_2016, and Gender_2017.

 

 

Does that help?

 


Hello @kgt_lena

 

 

I believe your last point is correct. You are able to concatenate your feature names when using a Dynamic writer. You mention wanting to have just the last portion of the feature type change. In your case, Gender_ would be the unchanging part, while the year would change. I don't believe you could use a Parameter as you would need to differentiate the features from one another. However, if you can use an Attribute that would work.

 

 

So if the Year attribute contains 2015, 2016 and 2017 in different features. Your writer feature type name would look like:

 

Gender_@Value(Year).

 

Which would output three different feature types with the names Gender_2015, Gender_2016, and Gender_2017.

 

 

Does that help?

 

Hello @trentatsafe

 

Yes, thanks, that does help indeed!

Reply