Skip to content

How to Change Multiple Column Names At Once

In Spotfire, there are two ways to change column names. You can modify the column names in Column Properties, or you can change them with Transformations. There are ramifications for which method you use, which I explained in this Data Shop Talk post. Now, speaking to Transformations….For years, I’ve been under the impression that you could only ever change one column name at a time. However, I recently found out that is not the case. It is possible to formulaically change multiple column names in one fell swoop (or expression…as it were). Let me show you how!

Occasionally, I have conversations with TIBCO regarding application features or suggestions that I make in the Ideas portal. It was after one of these conversations that Thomas Blomberg sent me this screenshot showing how to change multiple columns at one time.

Now, most of us learn to use simpler transformations than this and you cannot add multiple columns to the “Columns to Rename” section if you are just hand keying in a new column name. Thus, you wind up assuming you can only change one column name at a time.

As you can see in the screenshot above, if you are using a formula or function, such as this RXReplace function, multiple columns may be modified in a single transformation. Now I just need to learn regex.

If you enjoyed this, head over to the Data Shop Talk Archive to find my series on transformations.

Spotfire Version

Content created with Spotfire 10.2.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.