Using not equal to with wildcard

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to specify in my query criteria to leave out any record with an "I" or
a "B" in it. I got it to select every record with an I by using
Like "*I*"
However- how can i get it to exclude these records as opposed to including
these-
I tried
<>Like "*I*"
but this didnt work either. Any suggestions?
 
jjbf22 said:
I want to specify in my query criteria to leave out any record with
an "I" or a "B" in it. I got it to select every record with an I by
using
Like "*I*"
However- how can i get it to exclude these records as opposed to
including these-
I tried
<>Like "*I*"
but this didnt work either. Any suggestions?

....WHERE FieldName Not Like "*I*"
AND FieldName Not Like "*B*"
 
If I or B are the only characters within the field, I would make the criteria
like this:

<>"I"

It should then give you everything except the I's.
 
Try

NOT LIKE "*[BI]*"

'====================================================
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
'====================================================
 
Back
Top