Alteryx Designer Desktop Discussions

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

Using Append Field Tool for Multiple Variables

bwortham32
7 - Meteor

Hello All,

 

 

I'll try to explain this without confusing everyone.  Initially, I had the data below in which I had to use the Append Fields tool to calculate a % of business field.  I had to use this tool because my calculation multiples each row's Quantity by the Total Quantity in order to get the percentage.  My summarization going into the Append Fields tool target is grouped by State and Discount Level and summed by Quantity.  My summarization going into the source is the Sum_Quantity.

 

StateDiscount Level% of BusinessQuantity
OR5015%180
OR4015%180
OR3015%180
OR4510%120
OR3515%180
OR2510%120
OR2010%120
OR155%60
OR105%60
OR55%60

 

I would like to add another level to this with a snapshot of the data below.  I want to include % of Business based upon one extra variable (City).  Before, the % of Business totals 100% based on the State.  I would like the 100% to be rolled up to the city level.  Any ideas on how to do this?  I tried grouping City into the Source section along with the Sum_Quantity of the Append tool, but it does not seem to work.  Any help is greatly appreciated.

 

StateCityDiscount Level% of BusinessQuantity
ORPortland5055%165
ORPortland4040%120
ORPortland305%15
OREugene4520%80
OREugene3535%140
OREugene2525%100
OREugene2020%80
ORSalem1550%250
ORSalem1040%200
ORSalem510%50
2 REPLIES 2
Joe_Mako
12 - Quasar

How about the attached?

 

It will Summarize your data to the State-City combination level getting the Sum of Quantity, Join that back in with your original data on those two dimensions, and a Formula to calculate the percentage.

 

undefined

bwortham32
7 - Meteor

Thanks, Joe.  Not sure why I tried to complicate it so much!

Labels
Top Solution Authors