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

Monday as First day of the week 2

Status
Not open for further replies.

jeffwest2

MIS
Feb 5, 2009
64
0
0
GB
I can see some solutions within this, but I can't get any of them to work, so here goes.

I have to create a crosstab report that lists the days of the week at the top, I want to make Monday as the first day of the week, this is what I have at the moment on my crosstab column

DayOfWeek ({Report_Data.Import_DAte},crMonday )

This is what is showing

Sunday Tuesday Wednesday Saturday Total
1 125 238 150 116 629
2 111 211 42 141 505
3 21 53 1 39 114
4 16 1 0 21 38
5 6 0 0 6 12
6 0 0 0 2 2
Total 279 503 193 325 1,300

The numbers on the side are unimportant, how do I get it to show Monday as the first day, going from Monday to Sunday, I have been beating my head against a wall for about 2 hours now.

Thanks for the help.

Didn't anyone ever tell you? There's one thing you never put in a trap — if you're smart, if you value your continued existence, if you have any plans about seeing tomorrow — there's one thing you never — ever, put in a trap. … Me.
 
the easiest solution may be to use the specified order feature since there are only 7 days in a week

in crosstab expert select in the cross tab tab select your field under columns and then click on group options

in the columns tab select the second drop down box and select specified order and you can then out the days in that order



_____________________________________
Crystal Reports 2011 and XI
Intersystems Cache 2012 ODBC connection

 
In the crosstab, use the following formula a your column field:

dayofweek({table.date}, crMonday)

Then in preview mode, select the column label->right click->format field->display string->x+2 and enter:

weekdayname(currentfieldvalue,false,crMonday)

-LB
 
Thanks guys, that really helped.

Didn't anyone ever tell you? There's one thing you never put in a trap — if you're smart, if you value your continued existence, if you have any plans about seeing tomorrow — there's one thing you never — ever, put in a trap. … Me.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top