I was attempting to clean up an Alteryx workflow by injecting some standard macros where the workflow tends to sprawl. While converting a series of tools in Alteryx in to a standard macro, I noticed that a typical tool approach is yielding a completely different number of records than the standard macro equivalency.
Discrepancy in record quantity being pushed from identical processes
Standard macro setup:
Thank you for the help in advance!
Have you double checked to make sure each tool is configured exactly the same? Is the Unique tool using different columns to de-dup by chance?
If you output to a test file after the join, and then use that file as your Macro Input, what do those results look like when you just run the Macro from within the Macro itself?
Hey @ridodson ,
One weird thing I saw happening sometimes was related to a macro not outputting all the data when not having a connection to something right after.
Try adding a simple browse tool after the macro and see how it goes.
Best,
Fernando Vizcaino
@KSowers: Unfortunately, the macro returns the same number of records in the macro's canvas environment as it does in the workflow itself.
@fmvizcaino: I'll compare each tool again. When I initially designed the standard macro for the workflow, I had copied and pasted the white containerized section (see above) directly in to the standard macro immediately following its macro input tool. The Macro Input tool was created after I inserted an Output Data tool after the J anchor from the Join. I then converted it to an Input Tool, then converted that in to a Macro Input tool so the workflow and the macro were dealing with identical data sets.
Please add a browse after the macro in the workflow. Sometime you need to have it connected to a tool to show all records for macros.
If you are using a Unique tool with AMP and expecting same records to be output, you should be sure to use the "Engine Compatibility Mode" underneath the "Use AMP Engine" checkbox in the Workflow-Configuration Runtime settings. That will trigger the AMP Engine to use the same sorting method as the original Engine. You may see a slight performance decrease, but it should still be faster than not using AMP.
Here are more links to content about AMP Engine:
•Help Documentation
https://help.alteryx.com/current/designer/alteryx-amp-engine
https://help.alteryx.com/current/designer/Alteryx-Engine-and-AMP-Main-Differences
https://help.alteryx.com/current/designer/AMP-Memory-Use
https://help.alteryx.com/current/designer/tool-use-amp
https://help.alteryx.com/20221/designer/engine-compatibility-mode
https://help.alteryx.com/20221/designer/performance-profiling-amp-engine
https://help.alteryx.com/20223/designer/engines-parity-utility
Server:
https://help.alteryx.com/current/server/controller#configuration
https://help.alteryx.com/current/server/worker
https://help.alteryx.com/current/server/engine
https://help.alteryx.com/20223/server/amp-engine-best-practices
•AMP Engine Webinar (32 minutes)
•AlterEverything Podcast
•Community Blog posts
https://community.alteryx.com/t5/Engine-Works/AMPlify-your-Workflows/ba-p/617590