Unknown column 'x' in field list or where clause

Getting your data onto paper - or the web - Discussing the reports features of Base
Post Reply
One Big Yawn
Posts: 24
Joined: Sat Jul 14, 2012 6:09 am

Unknown column 'x' in field list or where clause

Post by One Big Yawn »

Greetings,

I am trying to run some reports based on a queries that include parameters. In the select statement of one, I have an IF statement

Code: Select all

IF(columnA= 'X', 123, 456)
X here is a string.

that gives me a
Unknown column 'X' in field list
Likewise, I have another query running

Code: Select all

WHERE columnA = 'Y'
where Y is a string

which yields and error
Unknown column 'Y' in 'where clause
I'm not sure what this means, as my SQL seems legit. I thought it might have something to do with syntax or using ' compared to `, but I'm not sure. Kind of sucks too, because I was ready to go live today... now I have to submit a watered down version. :ouch:

cheers
LibreOffice 3.5, MySQL 5.5, Windows 7
Post Reply