Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Macro batch is duplicating the result

Benjanez
6 - Meteoroid

Hello!

 

I need your help, I have created a macro batch, the macro is giving me the right result when I run it only the macro. However, when I use it in a workflow then the results (same input as I used to configure the macro) are repeated x100.

 

Attached the workflow, 

 

Any suggestion?

 

Thanks

 

Best,

6 REPLIES 6
RolandSchubert
16 - Nebula
16 - Nebula

Hi @Benjanez ,

 

my best guess would be, the problem is related to the settings for  "Group By", but I could be more specific, if you provide both the workflow and the macro (using "Export Workflow").

 

Best

 

Roland 

Benjanez
6 - Meteoroid

Hello Roland,

 

thank you! attached the workflow,

 

Best,

RolandSchubert
16 - Nebula
16 - Nebula

Hi @Benjanez,

 

my guess was not so bad ... you feed field "CS" in the control parameter, and it has 60 rows for "Product A", that means, the logic within the batch macro is executed 60 times for Product A (once for each row).

 

You can solve it by providing only unique values to the control parameter, e.g. by using a Summarize tool.

 

2022-06-15_11-50-36.png

 

Let me know if it works for you.

 

Best,

 

Roland

ddiesel
13 - Pulsar
13 - Pulsar

Hi @Benjanez!

 

Did this solution work for you?

Benjanez
6 - Meteoroid

Hello Roland!

 

Yes you were right, your answer was the solution. The only but, is that I have a NULL in the database and it started to give me an error. So, I delete that extra line I had and it ran perfectly. 

 

The little things here are the difference,

 

Thank you!

Benjanez
6 - Meteoroid

Yes! it is the solution, 

 

One point highlighted on my comment,

 

Best,

Labels