Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

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

Append title at the end of a string

rajputakansha
8 - Asteroid

Hi,

 

I have a column with same fields under different titles. I want to append the title names so as to differentiate them.

For example:

Input                               

ID
First Class
A
B
C
D
Second Class
A
B
C

Output

ID
A-First Class
B-First Class
C-First Class
D-First Class
A- Second Class
B-Second Class
C-Second Class

Is there a way to remove the headers and append it to the fields instead?

 

Thank you

6 REPLIES 6
meeravijayan2011
8 - Asteroid

Here is my solution for this

help.png

benakesh
12 - Quasar

Hi @rajputakansha ,

 

@meeravijayan2011  excellent solution . 

 

If there a  logic/rule to differentiate  heading  and data  ?   

Example  :  data is 1 character  and  heading contains  'Class'   

rajputakansha
8 - Asteroid

@benakesh@meeravijayan2011 

 

Thank you for your reply. It works great! But I am trying to make it more dynamic. For example:

 

Input 

IDS
West Chase
ABC
A7%RC
Host22
Swift#
Hilton Ranch
ABC
A7%RC
Host22
Date64Idea

 

Output

IDs
ABC- West Chase
A7%RC- West Chase
Host22- West Chase
Swift#- West Chase
ABC-Hilton Ranch
A7%RC-Hilton Ranch
Host22-Hilton Ranch
Date64Idea-Hilton Ranch

 

Appreciate your suggestions!

Thanks 

rajputakansha
8 - Asteroid

To make it bit easier, there is a null field before beginning of new header.

IDS
null
West Chase
ABC
A7%RC
Host22
Swift#
null
Hilton Ranch
ABC
A7%RC
Host22
Date64Idea
benakesh
12 - Quasar

Hi @rajputakansha ,

If your data  follows  the  rule   "null followed by header "  this works . 

benakesh_0-1574365120016.png

 

 

rajputakansha
8 - Asteroid

It works great! Thank you

Labels