I have an SQL Query that works as long as I am inside the statement builder ("Build SQL statement"-window), but when I finish and insert, the double quotation marks are confused by switch to mean the end of the SQL statement text.
I need the double quotation marks in the SQL statement though, because the columns in the database have spaces and dashes in their names (like for instance "Sell-To Name", that has both).
Is there a way to escape the double quotation marks in the SQL query text so that switch doesn't interpret them as an end to the "Database.Text:SQL"-variable?
This is the SQL Query that works in the statement builder, if I click "Validate statement":
Code: Select all
SELECT "Sell-To Name" FROM "åtta_45$PV Case" WHERE "Order No_" = '[Metadata.Text:Path="//field[tag='Ordernummer']/value",Dataset="Submit",Model="XML"]'
Code: Select all
[Database.Text:SQL="SELECT "Sell-To Name" FROM "åtta_45$PV Case" WHERE "Order No_" = '[Metadata.Text:Path="//field[tag='Ordernummer']/value",Dataset="Submit",Model="XML"]'",Connection="printvis"]