How do I use the " not like"

D

Derek

I am trying to pull out all records where the field (text value) does not
have "cell" in it. The feild has phrases in it, ie. "cell phone" or "dell
server" and when I try to use: not like 'cell%'. The problem is that it is
still bringing in the records containing cell phone. Any idea's, maybe im
using the wrong function?
 
M

Michel Walsh

Hi,


Have you tried with the classical Jet syntax, using * as wildcard:

NOT LIKE "*cell*"



The wildcard character to be used may be dependant of the context and of the
options you set. * and ? or % and _




Hoping it may help,
Vanderghast, Access MVP
 
M

[MVP] S.Clark

% is the pattern matching character for SQL Server & ADO.

* is used in Access Jet Databases.

Try: WHERE fieldname NOT LIKE "cell*"
 
Top