Where Clause SQL - DSS condition is a column
Noah
Registered Posts: 43 ✭✭✭✭
I have this query set up:
SELECT *
FROM "dbo"."Table"
where "COLUMN = "Value"
I get this Validation failed: Query failed: Invalid column name 'Value'.
Why does the DSS think I am saying where column = column
Answers
-
Hi @nshapir2
,Because 'Value' is a string literal, it needs to be enclosed in 'single quotes', not "double quotes".
SELECT * FROM "dbo"."Table" where "COLUMN" = 'Value'
For details, please see the following question: https://stackoverflow.com/q/1992314