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

Having a different axis label than what is grouped on in CR 2008

Status
Not open for further replies.

Alressler

Technical User
Feb 6, 2012
7
US
When you group on a CR report, you can change the label of the group. Such as I group by Year&Month so that I can sort a school year June - May but within a school year record. So even though the technical group says 11-June, the label on the report only says June.

Can you do this on a chart?
I have it sorting and displaying the data so that it matches the group data I have above it, but the axis label has 11-06-June (year month (for sort) and name) and I really just want it to say Jun as in 3 char months.

I'm using CR 2008 and just doing a basic chart and grouping above it from an Oracle view. Thanks!
 
When inserting a chart, you get an option to design it as a 'Grouped' or 'Advanced'. 'Advanced' allows you to "break" the chart on any field or formula of your choice (the Advanced option is not restricted to breaking the chart on the report grouping levels). So create a formula of your choice and "break" the chart on it.

hth,
- Ido

view, export, burst, email, and schedule Crystal Reports.
 
Ok I've been looking at the report and building the chart but I'm just not understanding what you mean by "Break". when I'm on advanced, it lets me use 'on change of' and I choose my custom formula and then it says show values - which is my summary of people. Where do I look to break the chart so I can display a different value rather than my custom formula on the axis?
 
I don't understand. How does that help me? I need to have it on my current on change of. That's the proper grouping. But I don't want that particular label to be on the axis labels for the data. Currently it says things like 12-06-jun and 12-07-jul and 12-08-aug (for all of the months) which is exactly how it needs to group and sort. But I need the labels to be Jun , Jul, Aug instead. Is this possible dynamically without redoing the labels? Because this report is dynamic and will change daily since it's an attendance report.
 
If I choose that then it doesn't sort properly. It sorts by the Month (Apr, Aug, Dec, Feb, etc). So I need it sorted properly in order of month number and by year, hence the 2011 - 06, 2011 - 07, 2011 - 08 custom formula for the on change.

I assume based on the above either you don't understand what I'm asking or you're saying there is no way that the axis label can be independent of the on change of label?
 
Set the formula to return: "1. Jan" "2. Feb" to retain the desired sort.

But you are probably right; I've been told many times my understanding is very limited.

view, export, burst, email, and schedule Crystal Reports.
 
Sorry, I looked again at your question and perhaps I truly didn't understand it (it's not clear to me what exactly you are grouping on). Assuming you are grouping your report on a date field, and electing to use the For Each Month option, then just customize the Group Name Field (using the Group Expert, Options button, Options tab) to use a formula expression such as: ToText({Your_Date_Column},'MMM')

Then, just insert Grouped chart, you would have the desired effect.

hth,
- Ido

view, export, burst, email, and schedule Crystal Reports.
 
You can either create a formula:

totext({table.date},"MMM")

...and then use Specified Order (select the "on change of" formula->order). You should set this up with all months initially (select at least a year's worth of data), so that the order is established for the report when there is a more abbreviated time period.

The other option is to choose the numeric axis chart type->one of the date options. You can then select the format in chart options, although it would still display the year, e.g., Feb-02.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top