This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Alteryx has been a great tool for someone who doesn't have a lot of SQL practice. I can use a simple query to get the raw data then start to transform it.
However, not all of my projects at work have room for an Alteryx step in them. I'm looking to convert or see the script my workflow is running to something resembling SQL. This would be a huge help when trying to write the SQL I'll eventually have to use on certain projects.
I understand it wouldn't be 1:1. I couldn't just plug & play but it would be a great resource.
Is there a way to export or view the underlying procedures a Workflow is running?
The easiest way would be to use In-Database (DB) tools to build your workflow (if you have a supported database) and to output the SQL query those tools generate.
Similarly to how you can Data Stream Out your records resulting from your In-DB operations, you can use the Dynamic Output In-DB Tool to output things like your connection name, data source, xml, and the SQL query that your In-DB operations would generate (up until that point in the workflow):
In this example I simply counted the unique Manager IDs from the table with the Summarize In-DB tool – you can see the SQL query does the same.
If you could set up a testing/temporary database connection to any one of those supported databases, you could emulate any one of your workflows using the In-DB tools and export the query that way.
You won't be able to "see" your workflow in SQL. The In-DB tools create a query that gets executed once all of the In-DB tools are configured and ran. In this particular post the user is wanting to use Alteryx to build the query and then use the query to execute against SQL. The Dynamic Output tool will give you that query. The In-DB tools create a temp table within your database upon execution to run the query and depending on how you have chosen to output the data the tools will then add your query to where ever you have chosen, then the temp table gets removed.
If your entire workflow is using In-DB tools, then you can get the query from the tools to use in SQL. I am not sure about Visual Studio, you would have to attempt. If you are using any tools other than In-DB tools, you will not be able to add that process into SQL.