|
-
May 24th, 2001, 11:47 PM
#1
Thread Starter
Member
Problem with SQL statement
I have an access database where I have a field called Description. This field contains all the description about a particular computer for example computer1 hard disk 10 GB, memory 64 MB.....
Now I would like to write a SQL Statement which will retrieve all records which contain the word 'Hard disk' in their Description field. Note that not all records will have the word 'Hard Disk'.
I have tried the following SQL statements but they do not work
first method:
select * from CompTable where Description in ("Hard Disk")
This method search for records where the Description field has only the word 'Hard disk' and no other words
Second Method:
select * from CompTable where Description like '%Hard Disk%'
The second method is better but Can I search 2 or more Keywords at the same time in the same SQL statement?
Are there any way where I can perform the desired query?
thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|