Where Clause SQL - DSS condition is a column

Noah
Noah Registered Posts: 44 ✭✭✭✭

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

  • Zach
    Zach Dataiker, Dataiku DSS Core Designer, Dataiku DSS Adv Designer, Registered Posts: 153 Dataiker
    edited July 2024

    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

Setup Info
    Tags
      Help me…