Skip to main content
Question

Rename feature classess in gdb (dynamic schema)

  • Nov 23, 2023 9:11 AM UTC
  • 6 replies
  • 150 views

marta.podsiad
Supporter
Forum|alt.badge.img+12

Hi,

 

I am trying to rename feature classes in the gdb. I have found couple posts about this but I got FAILED when I implementing suggested soutions. What am I doing wrong? image

6 replies

j.botterill
Evangelist
Forum|alt.badge.img+69
  • Evangelist
  • Nov 24, 2023 1:16 AM UTC

You may benefit from using a FeatureReader workflow transformer rather than a Reader. It has a schema port which will "list" the attribute names. AttributeCreator from - choose the "attribute{}" list index that represents the attributename you wish to rename; then set the value on the right. Also in the featuretype data stream, you need to rename the attribute. When both the schema and the data streams connection lines go into the writer, the changed attributename will meet up and write out dynamically


marta.podsiad
Supporter
Forum|alt.badge.img+12
  • Author
  • Supporter
  • Nov 24, 2023 12:03 PM UTC

Hi, the process above explains how to rename attributes. I would like to rename feature class


j.botterill
Evangelist
Forum|alt.badge.img+69
  • Evangelist
  • Nov 27, 2023 12:21 AM UTC

if you expose the fme_feature_type format attribute, you have a few other options:

  • use attributemanager/create where the output attribute fme_featuretype is set a conditional value
  • (perhaps easier) use attributevaluemapper to rename original feature class name to a new name

marta.podsiad
Supporter
Forum|alt.badge.img+12
  • Author
  • Supporter
  • Nov 28, 2023 3:30 PM UTC

Hi j.botterill,

 

I really appreciate your help but I cannot make it work


j.botterill
Evangelist
Forum|alt.badge.img+69
  • Evangelist
  • Dec 11, 2023 1:02 AM UTC

Hi Marta, I got back to this today. I made some changes as attached. I think you need to alter the fme_feature_type_name for the Schema data stream and then on the Data stream you change the fme_feature_type


marta.podsiad
Supporter
Forum|alt.badge.img+12
  • Author
  • Supporter
  • Dec 15, 2023 11:46 AM UTC

Hi, Unfortunately the workench fails. To clarify the purpose of this workbench is to rename feature layers in the gdb. image