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

group/loop over a field

becki
8 - Asteroid

I have a data set of dealership sales, for all dealerships.   for each dealership, i need to add up all the rows of sales, subtracting cancels of sales.  how do you loop over a field like that?  original data looks like :

 

yrmon       dealership_code transaction type   vin

032019        n98989              1                           <17 characters>

042019        n09090              -1

042019        n98989             -1

042019        n98989             -1

 

so i'd report:

032019     n98989        1

042019    n09090         -1

042019    n98989         -2

 

how do you loop over all yrmon combinations, adding up by dealership code, all sales minus cancels?

 

thanks

 

becki kain

3 REPLIES 3
danilang
19 - Altair
19 - Altair

Hi @becki 

 

For this, you can use a simple summarize with the following config

 

summarize.pngWF.png 

 

giving 

 

Results.png

 

Dan

itestu
Alteryx
Alteryx

Hi Becki,

 

Just use the Summarize tool with this configuration : 

  • group by | yrmon
  • group by | dealership_code
  • sum | transaction type

 

Irene

becki
8 - Asteroid

thanks, both worked once i made the field i was summing on an int, not a string

Labels