Adam Short wrote:
I've never needed it before but now I do!
Does anyone know if you are able to perform a NOT Like search using
Classic ASP ADO?
i.e. myData.Filter = "Ref NOT LIKE '*1234*'"
by the way this doesn't work!! and neither does myData.Filter = "Ref
<> LIKE '*1234*'"
or myData.Filter = "NOT Ref LIKE '*1234*'"
Regards
Adam
No, the NOT keyword is not allowed in the Filter property. While I echo
Ray's advice to use a WHERE clause in your sql string, I do recognized that
you may need to do multiple filters against the same set of records,
hopefully using a disconnected recordset. In this circumstance, here is a
workaround:
What you can do is use the Clone method to create a new copy of the
recordset, apply the filter to the clone using LIKE, delete the records
resulting from the filter from the clone and remove the filter.
Bob Barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.