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. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
PREVIOUS MONTH TIME FRAME IN QUERY?
Hi ,
I am trying to make querry which should give me the results from the whole previous month no mater when I am running that querry.in the current month. So I need the way to avoid typing date time frame for the previous month. Please help. Thank You in advance. Nedzad |
#2
|
|||
|
|||
PREVIOUS MONTH TIME FRAME IN QUERY?
....
WHERE [DateField] BETWEEN DateSerial( Year( Date() ), Month( Date() ) - 1, 1 ) AND DateSerial( Year( Date() ), Month( Date() ), 0 ) -- HTH Van T. Dinh MVP (Access) "Ned Beck" wrote in message ... Hi , I am trying to make querry which should give me the results from the whole previous month no mater when I am running that querry.in the current month. So I need the way to avoid typing date time frame for the previous month. Please help. Thank You in advance. Nedzad |
#3
|
|||
|
|||
PREVIOUS MONTH TIME FRAME IN QUERY?
WORKS PERFECT!
THANK YOU! "Van T. Dinh" wrote in message ... ... WHERE [DateField] BETWEEN DateSerial( Year( Date() ), Month( Date() ) - 1, 1 ) AND DateSerial( Year( Date() ), Month( Date() ), 0 ) -- HTH Van T. Dinh MVP (Access) "Ned Beck" wrote in message ... Hi , I am trying to make querry which should give me the results from the whole previous month no mater when I am running that querry.in the current month. So I need the way to avoid typing date time frame for the previous month. Please help. Thank You in advance. Nedzad |
Thread Tools | |
Display Modes | |
|
|