Renames attributes by adding or removing prefixes or suffixes, or replacing text in regular expressions or character strings.
This transformer is useful if you need to quickly rename all of your attributes. If the rename results in an empty attribute name, that attribute will be removed.
Features with attributes.
Features with renamed attributes.
Whether to rename All Attributes or Selected Attributes. FME attributes are prepended with "fme_".
The specific attributes to be renamed.
Indicates which action you want to perform:
- Add String Prefix: The string input for the String parameter will be prepended to all attributes.
- Add String Suffix: The string input for the String parameter will be appended to all attributes.
- Remove Prefix String: All attributes that start with the character sequence input for String parameter will be truncated to exclude the starting string character sequence.
- Remove Suffix String: All attributes that end with the character sequence input for String parameter will be truncated to exclude the ending string character sequence.
- Regular Expression Replace: The regular expression input for the Text To Find parameter will be replaced in all attributes with the character sequence input for the String parameter.
- String Replace: The character sequence input for the Text To Find parameter will be replaced in all attributes with the character sequence input for the String parameter.
- Change Case: All attributes will have their case changed according to the Case Change Type parameter.
Whether or not the original attribute names should be kept in addition to the new ones.
The regular expression or string pattern in each attribute name that should be replaced with the character sequence input for the String parameter.If the Action parameter is set to Regular Expression Replace then the Regex Editor will be available in the Text To Find parameter menu.
Whether or not the comparison should be case-sensitive.
The character sequence to prepend, remove, append, or use as replacement string.
- UPPERCASE changes attributes to uppercase characters.
- lowercase changes attributes to lowercase characters.
- Title case changes the first character in the string to its Unicode title case variant (or to uppercase if there is no title case variant) and the rest of the string lowercase.
- Full Title Case converts the first letter of each word, rather than just the first letter in the string. Full Title Case will ignore parentheses if they start the string or follow whitespace, and will treat hyphens (-) and underscores (_) as whitespace characters.
- Use the AttributeRenamer to rename individual attributes, with the option of supplying a default value if the original attribute was not present.
- Use the StringCaseChanger to change the case of attribute values.
Editing Transformer Parameters
Using a set of menu options, transformer parameters can be assigned by referencing other elements in the workspace. More advanced functions, such as an advanced editor and an arithmetic editor, are also available in some transformers. To access a menu of these options, click beside the applicable parameter. For more information, see Transformer Parameter Menu Options.
Test regular expressions with the Regex Editor in the parameter menu.
This transformer replaces the AttributePrefixer and the AttributeExpressionRenamer.
Search FME Knowledge Center
Search for samples and information about this transformer on the FME Knowledge Center.
Tags Keywords: AttributeExpressionRenamer AttributeNameCaseChanger, AttributePrefixer