The 502 Bad Gateway error is caused when a network error between servers on the internet. The failure is temporary or transient, please try to resubmit to try the flow again.
Besides, clear your browser’s cache and delete your browser’s cookies would always work.
Please also try to run the browser in a safe mode to see if it will work.
If you are still having the issue, please feel free post back.
I dont think its a network issue. If I get rid of the formalParemter and use straight SQL it works fine. At the bottom of the post you can see the error 'must decalare parameter giftyear;' .
This question is really about how to use formal parameters in a SQL Query
Thank you for posting on the Flow Community Forum! Have you had an opportunity to apply any of these recommendations to adapt your Flow? If yes, and you find that solution to be satisfactory, please go ahead and click “Accept as Solution” so that this thread will be marked for other users to easily identify!
Thank you for being an active member of the Flow Community!
Flow Community Manager
I can confirm that if you have the DECLARE section for each variable in 'formalParameters' then the query works as expected.
It'd be good if it was made apparent in the UI or in the error message that this DECLARE is required, as I assumed formal parameters were simply broken until I read this post.
It's not easy to find the documentation for Execute a SQL Query either - maybe this does mention this requirement. Could you point us to it?
EDIT: Actually it is not working. There is no error given but the SQL doesn't actually produce the result I'm expecting.
Is there any documentation for formalParameters? I'm very much at a loss as how to use the feature at all.
can you elaborate on what exactly is not working? Is the SQL query returning unexpected results, no results at all or do you have issues accessing / processing the resultset later in PowerApps etc. ?
Thanks and best regards