G
Guest
I'm created a QBF (query by form) that will search multiple fields for same
criteria. For example: I want search the Company Address, Primary Contact,
and CC fields for a the same name, say "Margaret"
Company | Contact | CC
ABC LA | Johnny | Sarah
ABC NY c/o Tom Slater | Tom Slater or Bob Fried | Margaret Hiffs
LMN | Margaret Tuttle | Roger Roberts
XYZ c/o Becky Thornbird | Bob Tucker | Liz Arwe
Now I know I would two records for Margaret, one for ABC NY & one for LMN
this is what I want.
Form: NameSearch, unbound box named [q_NameSearch]
Query: All fields with Company | Contact | CC fields having the following
criteria on different lines (an “orâ€): Like "*" & [Forms]![
NameSearch]![q_NameSearch] & "*"
When I run the query with form closed and get prompted for [
NameSearch]![q_NameSearch] it works fine. However when I do the search from
the form I get almost all the records (it excludes null fields) not the few I
need.
criteria. For example: I want search the Company Address, Primary Contact,
and CC fields for a the same name, say "Margaret"
Company | Contact | CC
ABC LA | Johnny | Sarah
ABC NY c/o Tom Slater | Tom Slater or Bob Fried | Margaret Hiffs
LMN | Margaret Tuttle | Roger Roberts
XYZ c/o Becky Thornbird | Bob Tucker | Liz Arwe
Now I know I would two records for Margaret, one for ABC NY & one for LMN
this is what I want.
Form: NameSearch, unbound box named [q_NameSearch]
Query: All fields with Company | Contact | CC fields having the following
criteria on different lines (an “orâ€): Like "*" & [Forms]![
NameSearch]![q_NameSearch] & "*"
When I run the query with form closed and get prompted for [
NameSearch]![q_NameSearch] it works fine. However when I do the search from
the form I get almost all the records (it excludes null fields) not the few I
need.