Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DateAdd including 1st of following month

Status
Not open for further replies.

LebronJames

Programmer
Apr 5, 2003
93
0
0
I have a datetime field where I want take the lastfullmonth... ONLY problem is I am getting the first of the current month as well..

Here is what I am using in the criteria field:

>=DateAdd("m",-1,Date())

This displays all of October but also giving me the first of Nov... WHY???????
 
I want take the lastfullmonth
In the query grid:[tt]
Field Expr1: Format([datetime field],'yyyymm')
Display unticked
Criteria =Format(DateAdd("m",-1,Date()),'yyyymm')

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
It worked... how can I say give me the records for this month... How can I say give me records for the year up to today
 
how can I say give me the records for this month
You really have no idea ?
What have you tried by your own ?
 
Thanks PHV the first day of the month no longer appears!! Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top