Query Returns Last Months Calls

brittaink

Registered User.
Local time
Today, 07:29
Joined
Dec 13, 2006
Messages
46
Hi,
Struggling a bit to enter expression. I have a [FaultOpened] Field in a table that stores the Date\Time that a fault is opened. I am trying to run a query that counts all Faults that have a fault opened date of between:
1st day of Last month - Last Day Of Last Month, or even just all faults that were opened Last month.

Tried the =DateAdd("m",-1,Date()) but will obviously open faults that were opened on this day last month.

Any ideas would be greatly appreciated. I think I am looking over the blindingly obvious.

Sorry

Keith
 
I think you have to change your approach, to something like this:

In a query field, insert:

Date: Format([FaultOpened],"mm-yy")

Then in the criteria, insert the month and year you require, such as "11-09".
 
So that you did not have to recode each time make that criteria
Format(dateadd("m",-1,date()),"mm-yy")

Brian
 

Users who are viewing this thread

Back
Top Bottom