Start Free Trial

Alteryx Designer Desktop Discussions

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

Date Age Column Issue

clarrock
8 - Asteroid

 

Hi,

 

I have a workflow where my input looks like this

Name2021-05-11Age9_442021-05-12Age9_452021-05-13Age
Sam120001130002  
Huge4400060  340001

 

I want my data as below for my further expressions :

 

Name2021-05-11Age9_442021-05-12Age9_452021-05-13Age9_46
Sam120001130002  
Huge4400060  340001

 

The Age column keep adding on so tomorrow it will, be Age.i want alteryx to check the previous Age column header and add a digit to it.

Is this possible? 

5 REPLIES 5
apathetichell
20 - Arcturus

The short is SURE! Can you explain though how the data is coming in/being updated. Is it a new file where the column i always called "age"?

 

Ideally it's probably easiest to transpose it and then perhaps use a multi-row or something to look for the row two rows above it (assuming that that is where the previous age is).

 

then you do something like

left([row-2:name],length(row-2:name]-1)+tostring(tonumber(right([row-2:name]),1))+1)

 

or something like that.

clarrock
8 - Asteroid

@apathetichell yes so everytime the data comes in as an input theres a new age column header with the recent date. I just want to modify the age column header to Age + (Prev age column+1) so  Age9_46

 

Could you share a workflow.. As I'm not able to get this to work. 

apathetichell
20 - Arcturus

Like this?

shreyanshrathod
11 - Bolide

 

@clarrock ,

With CROSSTAB, the output columns appear in sorted order and you will have to shuffle them back using a SELECT tool.

A more robust way of doing this would be using FIELD INFO and DYNAMIC RENAME.

shreyanshrathod_0-1620978076538.png

 

Have attached a workflow for your reference.

 

Regards,

Shreyansh Rathod

 

atcodedog05
22 - Nova
22 - Nova

An interesting different approach @shreyanshrathod 

 

Kudos to you 👍 and thanks for the share 🙂 

Labels
Top Solution Authors