Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Trim Character out of a column header

garretwalters12
8 - Asteroid

I am trying to Trim the first two characters of the column header (# and _) and would also like to remove all "_" which makes up the spaces.

 

Expected column headers:

 

June 2019

May 2019

Variance to Previous Month

June 2018

etc.

 

 

Column Header Trim.PNG

1 REPLY 1
LukeM
Moderator
Moderator

Hi @garretwalters12 

 

If you leverage the use of the Dynamic Rename tool, you can use a formula to update the column headers.

 

This would look like:

 

Trim(
Replace(
Right([_CurrentField_],Length([_CurrentField_])-1)
,'_',' ')
)

 

 

Which replaces the '_' with nothing and takes everything from the right except for the first value.

 

Hope this helps.

 

Luke

Labels