Link to home
Start Free TrialLog in
Avatar of ButchDog
ButchDog

asked on

Multiple criteria in Access Report

Hi All.

Creating a report in Access 2007 for the boss.

I have a field for the type of event that I need to filter out "DOC APPT"  and "Meeting".
I tried typing in the criteria line both of the above in quotes with "or" in between NOT in quotes.
I tried typing each on a separate line.
Either way it filters out the first but not the second.

I cannot believe this is so damn hard!!
I hate Access!

Any thoughts?
Thanks
B
Avatar of Dale Fye
Dale Fye
Flag of United States of America image

WHERE [Event Type] NOT IN("Doc Appt", "Meeting")

or an alternative might be:

WHERE [Event Type] <> "Doc Appt" AND [Event Type] <> "Meeting"
Avatar of ButchDog
ButchDog

ASKER

Ooops.
I screwed up.
I meant Query NOT report.
I'm working in Query view.
Duh!!

Does that change anything?
ASKER CERTIFIED SOLUTION
Avatar of mbizup
mbizup
Flag of Kazakhstan image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
<Does that change anything? >

You should generally avoid giving users direct access to your data through tables or queries, but rather use forms for data entry and reports for reporting data (this give you a lot more control).

The criteria fyed posted will work in a query.
Yes, I will design a report after I get the query working.

This really has to be done in VBA?
You'd think it would be simple enough to do right in the query design view.

Did I mention that I hate Access?

Thanks
I'll give your suggestions a try.

B
If you are entering this directly in the Criteria box in your query builder, use this:

NOT "Doc Appt" AND Not "Meeting"

(But I'd suggest putting this query behind a form or report if you are not doing that already, rather than opening it to general users)
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Got it!

Thanks to ALL!
:)

B