jramos74
asked on
Construct a SELECT query
How do I construct a SELECT query with a WHERE CLAUSE?
For example:
I want to find all records with columnname that has an apple word in it.
I know this query is wrong.
SELECT * FROM TABLE1 WHERE COLUMNNAME is in ('APPLE TART', 'apple', 'apple pie', 'Candy Apple');
For example:
I want to find all records with columnname that has an apple word in it.
I know this query is wrong.
SELECT * FROM TABLE1 WHERE COLUMNNAME is in ('APPLE TART', 'apple', 'apple pie', 'Candy Apple');
ASKER
Does the case format matter? Will this query pull records with 'APPLE' too?
which version are you using?
you can use ILIKE if you are using version 10g
you can use ILIKE if you are using version 10g
ASKER
Can you give me a select statement using ilike? I tried it and it did not work. We have 10g. My query is SELECT * FROM TABLE1 where columnname ilike '%apple%' and it did not work.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
tutorial linked below
http://www.techonthenet.com/sql/like.php