Alteryx Designer Desktop Discussions

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

Will Post Create SQL statement execute if the output table failed to write data

Progenitor
6 - Meteoroid

Hi Folks,

 

I have a simple use case where I am inserting data into a table in SQL server . I am writing a Control table in my Alteryx Output table Post SQL create statement just to keep the log that my table is refreshed for the day.However I am seeing issues,questions in the Alteryx community that Post create SQL statement execute in all cases even though table is not loaded properly or partially loaded and ran into some error after that.Is it the case.if yes how to deal with such caveats

1 REPLY 1
grazitti_sapna
17 - Castor

@Progenitor , I am not sure if post create SQL statement is being executed if the workflow fails. In my use case I was fetching data from a source and pushing it to an SQL server and in post create SQL statement I used a merge query. In any case, my workflow failed I never saw an update in the DB. The upsert happened only when the workflow successfully ran.

 

For debugging I can suggest you create a last modified date column or push a field from alteryx and check if your workflow fails does that field write data in the last modified date column of your table in the database or not? This gives us a clearer picture.

 

If the post create SQL statement writes data after the workflow fails then you need to add a current date timestamp field so that you can delete the data for that interval in case the worst-case scenario occurs. 

 

Thanks!

Sapna Gupta
Labels