A simple query? (1 Viewer)

DSrmi

New member
Local time
Today, 21:25
Joined
Apr 27, 2017
Messages
4
Hi All

My first post so sorry if its a bit of simple one, I've been reading through previous posts but can't seem to get this to work.

I have a Query to return information based on 3 criteria from information held in 2 different columns of a table named CD, the first column in the query is titled DOD which is a date field and the second titled MO a Yes/No field

In the DOD Column criteria I have the simple formula

>=[Report From] Or Is Null

Gives me a start date and includes any blanks in the column, this works fine however when I try to add the third criteria that is to also only return records where MO = Yes

If I remove the DOD formula, the MO query correctly returns the YES only results and If I remove the MO Yes criteria the DOD works correctly, I just cannot get them to work together? :banghead:

Thanks in advance!
 

NauticalGent

Ignore List Poster Boy
Local time
Today, 16:25
Joined
Apr 27, 2015
Messages
6,330
Is it possible to post a screen-shot of the query grid?
 

DSrmi

New member
Local time
Today, 21:25
Joined
Apr 27, 2017
Messages
4
Basic Grid

Many thx
 

Attachments

  • CD Query Grid.jpg
    CD Query Grid.jpg
    84.4 KB · Views: 68

NauticalGent

Ignore List Poster Boy
Local time
Today, 16:25
Joined
Apr 27, 2015
Messages
6,330
>=[Report From] Or Is Null

Is [Report From] a field in a loaded form? And if so, are you certain that you have records that would meet this criteria AND the [Mail Out] field set to True? It could be possible that you have no records that satisfy all three criterion.
 

DSrmi

New member
Local time
Today, 21:25
Joined
Apr 27, 2017
Messages
4
Hi NG

Both columns related to the same Table and are completed by the same form, I checked both the table and the form field properties and they appear to be set correctly,

DOD is a Date format **/**/**
MO is set at Yes / No - via combo box, value list drop box

I have about 2,000 records of which 400 meet the criteria on this occasion.

Although Access has now started asking me to enter the parameter twice before running the query which it wasn't doing earlier.

Thx
 

NauticalGent

Ignore List Poster Boy
Local time
Today, 16:25
Joined
Apr 27, 2015
Messages
6,330
Although Access has now started asking me to enter the parameter twice before running the query which it wasn't doing earlier.

Thx

I am surprised it wasn't asking you for a parameter from the start, given how your query is structured.

Rather than play 20 questions, can you zip your DB and post it here? It will really speed things up...
 

DSrmi

New member
Local time
Today, 21:25
Joined
Apr 27, 2017
Messages
4
Thanks for trying to help NG... unfortunately I am unable to post a copy of the DB.

I have since found a few problems in the DB structure which I corrected and that seemed to resolve the issue.

Thanks again
 

Users who are viewing this thread

Top Bottom