Free Trial

Alteryx Designer Desktop Discussions

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

created more columns

AnwarAlyafei
5 - Atom

I have a database with the names of people who donated; the donations could have different purposes and be produced by the same person. 

My problem is that for each donation, I have a new row with the same name but a different "purpose" for those who donated for multiple purposes.  How do I stop the name from repeating on various rows and create "purpose1, purpose2, Purpose3" columns? Purpose 3 is the last column. 

 

3 REPLIES 3
CoG
14 - Magnetar

Have you tried using the Cross Tab Tool? If you could provide an excel file with sample input and output, more help can be provided.

Yoshiro_Fujimori
15 - Aurora
15 - Aurora

Hi @AnwarAlyafei ,

 

As @CoG suggested, that would be a use case of Cross Tab tool.

 

First you may check the interactive lesson https://community.alteryx.com/t5/Interactive-Lessons/Changing-Data-Layouts/ta-p/82876.

A sample workflow is attached for your reference.

Good luck.

 

Input Data

NameAmountPurpose
a1purpose1
a2purpose2
a3purpose3
b4purpose1
b5purpose2
b6purpose3
c7purpose1
c8purpose2
c9purpose3

 

Workflow

CrossTab_workflow.png

Configuration

CrossTab_config.png

Output Data

Namepurpose1purpose2purpose3
a123
b456
c789

 

 

Qiu
21 - Polaris
21 - Polaris

@AnwarAlyafei 
I feel the data for Purpose is not really Purpose per se. 😁 so maybe it is more something like this?

0801-AnwarAlyafei-A.png0801-AnwarAlyafei-B.png

Labels
Top Solution Authors