A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Muliple Critera



 
 
Thread Tools Display Modes
  #1  
Old January 21st, 2010, 03:13 PM posted to microsoft.public.access.queries
K
external usenet poster
 
Posts: 287
Default Muliple Critera

Hello,

I have a query that refers to fields in a form to search.

Form (frm1) Field names / search critera are as follows:
Date Start
Date End
Branch / Plant
SIN

I was wondering, how can I configure the select query that if one of the
fields above is left blank or Null that it will still work based on fields
that are not null? For example, I have no Start or End date however have SIN
(Short Item number) meaning that I want all records based on this SIN only. I
cant get it to work if fileds are null. I have tried placing the criteria in
the OR field and still doesnt work. Only works if all fields have an entry
on the form

Any help would be appreciated. Thanks, Kyle
  #2  
Old January 21st, 2010, 03:38 PM posted to microsoft.public.access.queries
Duane Hookom[_4_]
external usenet poster
 
Posts: 316
Default Muliple Critera

A typical criteria expression under the Branch field might be:
Forms!frm1!Plant or Forms!frm1!Plant Is Null

Duane Hookom
MS Access MVP

"K" wrote in message
...
Hello,

I have a query that refers to fields in a form to search.

Form (frm1) Field names / search critera are as follows:
Date Start
Date End
Branch / Plant
SIN

I was wondering, how can I configure the select query that if one of the
fields above is left blank or Null that it will still work based on fields
that are not null? For example, I have no Start or End date however have
SIN
(Short Item number) meaning that I want all records based on this SIN
only. I
cant get it to work if fileds are null. I have tried placing the criteria
in
the OR field and still doesnt work. Only works if all fields have an
entry
on the form

Any help would be appreciated. Thanks, Kyle


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 02:59 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.