I appreciate your help here as this is my first time using SQL Workbench.
I am connected to my database. I have a table called "apartments" with a column named "apt_name". For every row that contains abc, I want the value in column "zip" and I need that data exported.
So far I can't even get this to work by entering it into the Statement 1 tab and hitting the execute button. "Invalid operation: syntax error at or near "CONTAINS".
SELECT * FROM apartments WHERE apt_name CONTAINS 'abc'
Thanks again.
Please try this:
SELECT * FROM apartments WHERE 0<>CHARINDEX('abc',apt_name)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.