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
|
|||
|
|||
Year to Date
How could I put restrictions in Criteria for the current
year to date in the one field and for the previous year to date in the second field to compare the data? Thanks |
#2
|
|||
|
|||
Year to Date
On Tue, 20 Jul 2004 13:00:29 -0700, "Alex"
wrote: How could I put restrictions in Criteria for the current year to date in the one field and for the previous year to date in the second field to compare the data? Thanks Add the table to the query grid TWICE; join by whatever key field identifies what it is that you want to compare over years. Then in one instance put = DateSerial(Year(Date()), 1, 1) AND = Date() as a criterion on the date field; in the second instance use = DateSerial(Year(Date()) - 1, 1, 1) AND = DateSerial(Year(Date()) - 1, Month(Date()), Day(Date())) John W. Vinson[MVP] Come for live chats every Tuesday and Thursday http://go.compuserve.com/msdevapps?loc=us&access=public |
#3
|
|||
|
|||
Year to Date
Could you type in about 10-12 records as well as your expected display? It
would save us from making WAGs regarding what you have and what you want. -- Duane Hookom MS Access MVP "Alex" wrote in message ... How could I put restrictions in Criteria for the current year to date in the one field and for the previous year to date in the second field to compare the data? Thanks |
#4
|
|||
|
|||
Year to Date
Thanks a lot, John.
These are the formulas I needed. How could I interpret it if my fidcal year is Aug 1 to Jul 31? Thanks -----Original Message----- On Tue, 20 Jul 2004 13:00:29 -0700, "Alex" wrote: How could I put restrictions in Criteria for the current year to date in the one field and for the previous year to date in the second field to compare the data? Thanks Add the table to the query grid TWICE; join by whatever key field identifies what it is that you want to compare over years. Then in one instance put = DateSerial(Year(Date()), 1, 1) AND = Date() as a criterion on the date field; in the second instance use = DateSerial(Year(Date()) - 1, 1, 1) AND = DateSerial (Year(Date()) - 1, Month(Date()), Day(Date())) John W. Vinson[MVP] Come for live chats every Tuesday and Thursday http://go.compuserve.com/msdevapps?loc=us&access=public . |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Aggregating Date Data into Weeks and Quarters | Roger | Running & Setting Up Queries | 3 | July 11th, 2004 05:56 PM |
Does date fall between two ranges? | MR | Worksheet Functions | 4 | January 14th, 2004 04:08 PM |
date conversion | web_time | Worksheet Functions | 10 | December 25th, 2003 06:51 PM |
type date and year has to come. | shital | Worksheet Functions | 6 | October 6th, 2003 01:49 PM |