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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to chart data in subreport between two dates

Status
Not open for further replies.

ebstarasia

IS-IT--Management
Mar 9, 2011
62
US
I have a report that displays monthly values and its trailing values (rolling average last 12 months). In order to have these data charted they are passed down into a subreport.

The difficulty that I am coming across is charting data points between two dates. For example, the data selects data from a date range between 06/2003 to 3/2011 and I need to chart the data from a date within these dates, say 01/2010 to 01/2011.

For the data to be correct it must have data ranging more than 12 month previous to the starting date needed to be charted. Example for data beginning and needed to be charted for 01/2010, it must use the data from the previous 12 months.

When I use the select expert it will start getting the data starting at 01/2010, therefore thinking that the data for the previous 12 months is zero.

Correct me if I am wrong but I figured to that I could create some parameters to
1)select the data range for the report to use i.e. 06/2003 to 03/2011
2)select the data range to plot in the subreport i.e. 01/2010 to 01/2011

any suggestions?
 
You can use a parameter for the chart begin date, and then in the sub, go into the report->selection formula->record and change the formula by adding -365 to the start date parameter.

-LB
 
im a little lost as to where to add that. my selection formula in the subchart is:

toText(date(year({T_OIMMAIN.F_PostDate}),month({T_OIMMAIN.F_PostDate}),1),"MM/dd/yyyy") in split({?Pm-@OnChangeOf},"^");
 
Please ignore my previous response. If you are getting the correct values in the body of the report, then the values passed should be correct as is. If you only want to chart a subset of the data in the main report, then you should be limiting the values collected in your OnChangeOf formula and ShowValue formulas in the main report by adding a clause to each that limits the dates.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top