To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
hello all,
My SQL script with GO statements in them works fine is SSMS, it is able to query the database.
But when I copy the script in Power Query's SQL Statement to make connection with the database, it gives me the following error
But when I take the GO statements out, the PQ is able to connect with the database.
Am I able to fix this error or is GO statement not allowed in PQ?
Solved! Go to Solution.
Not allowed. You can only run queries*, not transactions.
Use a Stored Procedure or a view to hide the "ugly" code from Power Query.
* yes, I said queries. While you are supposed to only ever run a single SELECT query, it is unfortunately technically possible to chain all sorts of crazy queries as long as the last one is a SELECT.
Not allowed. You can only run queries*, not transactions.
Use a Stored Procedure or a view to hide the "ugly" code from Power Query.
* yes, I said queries. While you are supposed to only ever run a single SELECT query, it is unfortunately technically possible to chain all sorts of crazy queries as long as the last one is a SELECT.