Why is this query simplification not working

AlokOfAarmax

New member
Local time
Today, 07:30
Joined
Apr 22, 2013
Messages
5
Hi Friends
I was trying to simplify a condition for a field in a query:
I replaced

Not Like "*Payables*" And Not Like "*Receivables*"

with

Like "*Payables*" Or Like "*Receivables*"

and got completely different results.

Can someone explain why this is so?

Thanks.
 
I expect they returned the opposite result set. The first gets anything NOT like the 2 criteria, the second gets anything that IS like the criteria. In other words, the first gets everything but payables and receivables, the second only payables and receivables.
 
Thanks Paul.

For some reason I thought I was simplifying the query. I was in mind simplifying the opposite of the query Not ( Not Like "*Payable*" And Not Like "*Receivable*").

I feel very stupid now.

Alok
 
No problem. We've all done it. ;)
 
AlokOfAarmax;

See this link for more info (probably more than you'll ever want) DeMorgans Laws

OR Also DeMorgan

Not (A and B) ==== Not A OR Not B

Not (A OR B) =====Not A AND Not B
 

Users who are viewing this thread

Back
Top Bottom