community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
#SANTALYTICS

The highly anticipated Alteryx Community tradition is back! We hope you'll join us!

Learn More
SOLVED

Combining Multiple Rows into one with additional columns

Highlighted
Atom

Hi, I am trying to combine some rows based on employee name or employee ID and display the year to year salary all on the same line instead of in multiple row entries. 

 

Current look: 

 

Employee NameEmployeeIDYearSalary
Joe101201210,000
Tom202201212,000
Joe101201313,000
Tom20220149,000
Tom202201511,500

 

What I would like the output to look like: 

 

Employee NameEmployeeID2012 Salary2013 Salary2014 Salary2015 Salary
Joe10110,00013,000--
Tom20212,000-9,00011,500

 

I am still running into the issue of outputting multiple rows for the same employee name and employeeID

 

Any and all help would be appreciated. Thanks in advance!

Alteryx Certified Partner
Alteryx Certified Partner

@mrobo

 

It sounds like you have the Cross Tab portion figured out, but just need to consolidate salary values by employee and year first. I used your example data to first convert the salary data to a numeric field and summed by employee and year. Then a Cross Tab and Rename took care of the rest. Solution attached.

 

Pulsar

Uploading a sample workflow for your case. Cross Tab tool will help you to get the desired results. 

 

workflow.PNGresults.PNG

Labels