Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Queries / May 2006

Tip: Looking for answers? Try searching our database.

having problems using multiple criteria in query...help

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Melle Mel - 02 May 2006 16:41 GMT
I have a query with multiple criterias in one or more fields.  I have updated
this query to include yet another criteria in a different field and for some
wierd reason, it is not returning the value of my selected criteria.  So
instead of returning back certain records, it gives me all records.  The
field is Mail Type and the criteria choices are coming from a drop down menu:
E-Newsletter or Hard Copy.  The criteria I entered is: = E-Newsletter and I
even tried <>Hard Copy.  Both ways are producing no change/criteria specific
records.  

To test the functionality, I created a dummy query and just only selected
the one criteria (i.e. E-Newsletter) and it returned back the correct
record(s).  However, in the actual query that contains multiple criteria, it
doesn't work.  Is there any sane reason why?  Your help would be greatly
appreciated.
KARL DEWEY - 02 May 2006 18:36 GMT
How are you adding the additional criteria?  Are you in the design view grid?
Remember that criteria placed on the same row forms an AND function in that
both criterias must be satisfied.  If you place the criteria on separate rows
then either will satisfy the requirement.

> I have a query with multiple criterias in one or more fields.  I have updated
> this query to include yet another criteria in a different field and for some
[quoted text clipped - 10 lines]
> doesn't work.  Is there any sane reason why?  Your help would be greatly
> appreciated.
Melle Mel - 02 May 2006 18:57 GMT
Yes, I am in design view.  And yes, I isted the criteria on the same line/row
to evoke an AND function, meaning I want all criterias satisfied versus 'OR'.
Yet, it doesn't work.  For instance, I want data that meet criteria in
COMPANY field of "USA" and in the MAIL TYPE field I want data that meet
criteria of E-newsletter.  Yet when I run the query, it acts as if there is
no criteria for MAIL TYPE field, although it accepts the other listed
criterias (and yes, I have probably 4-5 other fields with AND criterias all
going at the same time)

> How are you adding the additional criteria?  Are you in the design view grid?
> Remember that criteria placed on the same row forms an AND function in that
[quoted text clipped - 15 lines]
> > doesn't work.  Is there any sane reason why?  Your help would be greatly
> > appreciated.
KARL DEWEY - 02 May 2006 21:11 GMT
Try doing the reverse.  Save a copy of query under another name and then edit
so only MAIL TYPE field has criteria, run.

Build a little, test a little.

> Yes, I am in design view.  And yes, I isted the criteria on the same line/row
> to evoke an AND function, meaning I want all criterias satisfied versus 'OR'.
[quoted text clipped - 24 lines]
> > > doesn't work.  Is there any sane reason why?  Your help would be greatly
> > > appreciated.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.