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!

Day Of Week in Bar Chart

Status
Not open for further replies.

gtf

Programmer
Oct 1, 2002
16
CA
I want to use a side by side bar chart to show the number of widgets sold by day of the week. I want the days to be Mon, Tue, Wed ...etc and not 2, 3, 4 ...etc. When I use dayofweek({MY.DATE}) I get 2, 3, 4 in my chart. When I use:["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"] [dayofweek({MY.DATE})] I get the name but it is sorted by that name. ie. Fri comes first. I am using CR XI & MSSQL 2005 db.
 

In the Chart Expert, make the "On change of" to be the dayofweek({MyDate}) formula. In the same dialog, click the Order button and change to "in specified order"

This works the same as specified order grouping - create a named group called Monday, and edit the formula to say {@DayFormula} = 1. Repeat with the other days - Tuesday would be {@DayFormula} = 2, etc.

 
Thanks briangriffin, you got me on the right path. I used the following formula: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"] [dayofweek({MY.DATE})]
and then did the "in specified order" in the Chart Expert. It works fine now.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top