Skip to main content
Solved

How to Quickly Rename Referenced Attributes in Multiple Transformers

  • August 7, 2024
  • 3 replies
  • 92 views

ecx
Supporter
Forum|alt.badge.img+6

I have a complex workflow where a specific attributes, i.e. “PositionID”, which are referenced across multiple transformers. I need to rename these attributes to another name throughout the entire workflow. Manually opening each transformer to change the reference would be very time-consuming.

Is there a way to quickly rename this attribute in all transformers without having to edit each one individually? Any tips or tools within FME that can help streamline this process would be greatly appreciated.

Alternatively, next time I create a project can I set these up as parameters or variables and reference them that way and hence change them more easily?

 

Thanks

Best answer by virtualcitymatt

One way to do it is to just first rename the attribute to match what you have used in the workspace. you can then rename it at the end again before you write it out. If the workspace is big enough that’s what I usually do.

if you expect the attribute name to change often you can indeed set up a parameter to help with this.  





 

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.

3 replies

virtualcitymatt
Celebrity
Forum|alt.badge.img+47

One way to do it is to just first rename the attribute to match what you have used in the workspace. you can then rename it at the end again before you write it out. If the workspace is big enough that’s what I usually do.

if you expect the attribute name to change often you can indeed set up a parameter to help with this.  





 


jkr_wrk
Influencer
Forum|alt.badge.img+35
  • August 8, 2024

As long as the name within your workbench is logical I would go with @virtualcitymatt solution. Rename it at the start and rename it at the end.

You could try to open the fmw file as text and stringreplace all instances of PositionID . But it can easily corrupt your workbench.


hkingsbury
Celebrity
Forum|alt.badge.img+65
  • Celebrity
  • August 8, 2024

You can open the .fmw file in a text editor and do a find and replace….

You do run the risk of breaking the entire workbench! So do so carefully and make sure you have a backup.