Alteryx Designer Desktop Discussions

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

Macro for Tiles

Cela
8 - Asteroid

Hey everyone,

I have the challenge to first split the initial input into unique tiles and merge them after their respective calculations back together. I am aware that I could basically just filter based on the Tile number and then do this n-times but I would prefer having a macro since the steps for each tile group are the same (first row is skipped, data cleansing to remove null rows and formula for calc) and therefore standardised.

 

Does anybody have an idea how I could kick start this split and merge dynamically (n-amount of tile groups)?

 

Thanks in advance!

5 REPLIES 5
caltang
17 - Castor
17 - Castor

I think the best way for us to advise you is to see what we're dealing with. So you're splitting something and then merging them back together for some reason - maybe there's a better way or we can try a different route instead of a batch. Do you mind providing some data and some expected outputs?

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
Cela
8 - Asteroid

Hi caltang,

 

here is a very simple example of how I was tiling it so far:

 

InvoiceNumberSalesFileNameValueTile_NumTile_SequenceNum
SI1000021774A12345611
SI1000021774B12345612
SI10000219992199912345621
SI10000111111111112345631
SI10000111231112312345641

 

Now I would like to split them based on the column "Tile_Num" which is easy if you know how many you need and the batch of tile groups is a small number.

 

Hope it helps to make my point clear.

caltang
17 - Castor
17 - Castor

Hi @Cela 

 

If you're skipping every 1st row and cleansing it then formula it, why don't you try the Sample tool instead:

image.png

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
Cela
8 - Asteroid

Thank you for the suggestion @caltang!

I am using the sample tool for the skipping after the tiles are split up because I need to skip every first row of each tile group. In the example above I end up with 4 separate results as there are 4 tile numbers. If the sequence was longer for each tile number, I would have to skip the first row respectively.

What I am looking for is a way to let tile number 1 run through a batch macro first, then number 2 and so on until n.

My idea for now is to update the value of the filter tool based on Tile_Num so that the reference remains variable.

 

Would you happen to have a suggestion for this scenario?

caltang
17 - Castor
17 - Castor

Hmm, the way you're looking at it is to filter for each Tile_Num and then run a process through it, then spit it out. Repeat n times until all Tile_Num are exhausted right? 

 

Now, that's fine but I still don't get why you need to batch it sequentially. What sort of formula are you applying to it that requires for it to one by one? 

 

If you're already skipping the 1st row, you can continue with the Sample tool. So I still fail to comprehend the need... it's a slow Wednesday for me so I need some more context if you can... maybe a larger sample data set and an expected output will help tremendously. 

Calvin Tang
Alteryx ACE
https://www.linkedin.com/in/calvintangkw/
Labels
Top Solution Authors