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

Grouping on chart and passing the section printing by formula 1

Status
Not open for further replies.

americvish

IS-IT--Management
Aug 5, 2010
26
US
I am creating a chart in the report,placing it in the group header grouped by metric_name and where the "on change of" is on date field based on formula.
the formula is like if order_date in {?start_date} to {?end_date} then order_date.
and show values on order_amount.
and there is a parameter data_interval which has values monthly,weekly,daily,hourly and raw.

i want the report to appear according to the data interval selected if monthly the data on x-axis should appear in monthly interval ,if weekly then appear weekly and so on.


i am inserting the order date in on change of and disabling the section to be printed by selecting the group sort order by mention as crAscending in the formula in order for date field and order_amount in show values.

but not able to workout in presenting the chart with the data interval.

can somebody pls do suggest on this issue.
 
You need to build the intervals into your "on change of" formula, e.g.,

if order_date in {?start_date} to {?end_date} then
(
select {?Interval}
case "Monthly" : datetime(year({table.datetime}),month({table.datetime}),1,0,0,0)
case "Weekly" : datetime(date({table.datetime})-dayofweek({table.datetime})+1, time(0,0,0)
case "Daily" : datetime(date({table.datetime}),time(0,0,0))
case "Hourly" : datetime(date({table.datetime}),hour({table.datetime}),0,0)
)

Or something much like this.

-LB
 
can you pls mention the formula for the below:

for each day
for each week
for each two weeks
for each half month
for each month
for each quarter
for each half year
for each year
for each second
for each mintue
for each hour
for AM/PM

and how would i make the chart to drill down .
if the user select the chart as monthly,he should be able to drill down it to weekly then to daily then to hourly?

and thanks for your response it worked out.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top