Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"SQL0206N SQLSTATE=42703". Please help me understand. 1

Status
Not open for further replies.

tbtcust

Programmer
Oct 26, 2004
214
US
Hi all,

I have a table with 3 columns that makeup the key. Col_1 varchar 128, Col_2 integer, and Col_2b varchar 128.

When I use Col_1 or Col_3 in the WHERE clause of a query it fails with "SQL0206N " Col_1" is not valid in the context where it is used. SQLSTATE=42703". See query below. Col_2 integer works fine. Also, there are for other sechma in the database with the same table and column name. Can some help?

Thanks in advance for any help.

SELECT Schema.Table_1.Col_1
FROM Schema.Table_1
WHERE Schema.Table_1.Col_1 = "ABCD"
 
Try out

SELECT Table_1.Col_1
FROM Schema.Table_1
WHERE Table_1.Col_1 = 'ABCD'
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top