accessaspire219
Registered User.
- Local time
- Today, 13:40
- Joined
- Jan 16, 2009
- Messages
- 126
I have a query which has a column called period. The period column contains months (mmm/yyyy) and year (yyyy YTD) for the data that the query generates.
I want to define a criteria for this query so that the user can specify a range of months that he wants to the data for along with the YTD total. (For the type of calculation required, YTD cannot be calculated from the monthly result so they have to be two separate calculations)
Now, I have specified the criteria as Between [Forms].[Form1]![StartDate] And [Forms].[Form1]![EndDate]
However this criteria does not include the YTD records since do not fall in the range. I would like to define a criteria so that it displays the YTD based on the year of the EndDate for example:
Between [Forms].[Form1]![StartDate] And [Forms].[Form1]![EndDate] And Like [EndDate](“yyyy”)
Does any know how this can be done?
Any help is appreciated!
Thanks!
Jan-09
Feb-09
Mar-09
Apr-09
May-09
Jun-09
Jul-09
Aug-09
Sep-09
Oct-09
Nov-09
Dec-09
2009 YTD
Feb-09
Mar-09
Apr-09
May-09
Jun-09
Jul-09
Aug-09
Sep-09
Oct-09
Nov-09
Dec-09
2009 YTD
I want to define a criteria for this query so that the user can specify a range of months that he wants to the data for along with the YTD total. (For the type of calculation required, YTD cannot be calculated from the monthly result so they have to be two separate calculations)
Now, I have specified the criteria as Between [Forms].[Form1]![StartDate] And [Forms].[Form1]![EndDate]
However this criteria does not include the YTD records since do not fall in the range. I would like to define a criteria so that it displays the YTD based on the year of the EndDate for example:
Between [Forms].[Form1]![StartDate] And [Forms].[Form1]![EndDate] And Like [EndDate](“yyyy”)
Does any know how this can be done?
Any help is appreciated!
Thanks!