Alteryx Designer Desktop Discussions

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

Nested Iterative Macro inconsistent results

mrhobler
5 - Atom

I have built a set of nested iterative macros to help allocate component inventory that is needed to build finished goods.  The problem that I am running into is that the 2nd macro gives inconsistant results.

 

What I mean is that if you use the top filter that limits the input to 3 componenets everything works correctly.  

 

Macro one limits the workflow to a single week and passes that one to the 2nd macro which does the iteration at a TLA (Top Level Assembly).  In this macro it takes the inventory for all of the parts that are used in that TLA and applies it to the 1st TLA and then moves any excess inventory to the next instance where that part is used.  (Not all TLAs use the same parts).

 

This output then gets passed  back to the 1st macro which then moves any inventory left from the 1st week to the 2nd week and then the process starts again.

 

If you view the output from the top filter you will notice that the remaining inventory numbers are populated (when it is appropriate). 

mrhobler_0-1610681055529.png

 

If you link to the bottom filter which adds in another component you will see that the invnetory is not being pass down.

mrhobler_1-1610681136105.png

 

I am obvioously missing something but I don't know what so any help would be appreicated.

1 REPLY 1
clmc9601
13 - Pulsar
13 - Pulsar

Hi @mrhobler,

 

Hmm this is puzzling. I have some recommendations for you to make troubleshooting easier:

- rather than resetting column values to 0 all the time (this happens 3-4 times for some columns), try creating new columns with more descriptive names and then only reset once at the end. OldSC, SC, then you can use Multi-row to adjust. 

- be cautious that max row ID and max supply might not always come from the same row, but your summarize treats them like they do

- start simple when building macros. Fewer steps make it easier to understand and troubleshoot. Then add complexity once you know it works for your range of product components. IE, wait to nest macros until you know for sure the inner one works.

- honestly, I didn't figure out why the problem would be occurring. If you're still troubleshooting this, I'd recommend unnesting the macro (take a single week first, for example) and simplifying steps.

Great idea to add multiple outputs to your inner macro though!

Labels