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!

How to Set DATEFIRST?

Status
Not open for further replies.

cityboy3

Programmer
Nov 6, 2002
41
US
I have defined a time dimension based on a date field in my fact table (needed a quick and dirty analysis). For my analysis, I need to look at weekly aggregations. However, my company's week starts on Monday. I know that in a stored procedure, I would be able to SET DATEFIRST before using the DatePart function to get a week number. My question is: How do I set this in my dimension definition? In the Dimension Editor, my Member Key Column property looks like this:
DatePart(week,"dbo"."ScheduleOfService"."FromDateTime")
How do I tell it that the week starts on Monday?
thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top