More Than One Field Query

Z

zyus

I hv 3 fields addr1 , addr2 and addr3.

How do i make a simple query to find record with "abc" in either one of the
3 fields.

Thanks
 
P

pietlinden

I hv 3 fields addr1 , addr2 and addr3.

How do i make a simple query to find record with "abc" in either one of the
3 fields.

Thanks

SELECT *
FROM mytable
WHERE Addr1 = "abc"
OR Addr2 = "abc"
OR Addr3 = "abc";
 
J

John W. Vinson

I hv 3 fields addr1 , addr2 and addr3.

How do i make a simple query to find record with "abc" in either one of the
3 fields.

Thanks

In the query grid, put

LIKE "*abc*"

on the criteria lines under the three fields, on *three separate lines* in the
query grid. This will create "OR" operators to combine the criteria.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top