Weekday

Weekday

Post by Humberto Pannefle » Wed, 06 Feb 2002 06:44:38



Hi,
I started creating cubes last week, so I'm very new at
this.  One of the cubes I'm creating shows sales by week.  
The problem is that our week starts on Mondays and the
default is for Sundays.  How do I change the default?
Please help.

Thanks!

 
 
 

Weekday

Post by Danie » Thu, 07 Feb 2002 13:34:01



This can set the default starting day

Quote:>-----Original Message-----
>Hi,
>I started creating cubes last week, so I'm very new at
>this.  One of the cubes I'm creating shows sales by
week.  
>The problem is that our week starts on Mondays and the
>default is for Sundays.  How do I change the default?
>Please help.

>Thanks!
>.


 
 
 

Weekday

Post by Mo Lin[M » Thu, 07 Feb 2002 15:44:22



check whether the returned value equals 7. If so, execute "SET DATEFIRST  
1" to force SQL Server to use Monday as the first day of the week.

This posting is provided "AS IS" with no warranties, and confers no rights

Regards,
Mo Lin
Microsoft Support Engineer

 
 
 

Weekday

Post by Mo Lin[M » Thu, 07 Feb 2002 17:42:25


Hi,

As the method that I provided in the previous post  is connection
dependent, says, If a new connection is made to SQL Server or if the server
is stopped and restarted, the setting of date first will go back.

It is hard to set datefirst from Analysis Service directly. The followig I
am introducing a workaround for your reference,

1. In SQL Server Enterprise Manager, create a login with default language
"British_Englisg". (By default, for "us_english" the first day of the week
is Sunday, but for "British_Englisg", the first day of the week is Monday.)

2. Grant the required permisions to it.

3. Using this login ID in cube data source to connect SQL Server.

Then, sales by week will start on Monday.

This posting is provided "AS IS" with no warranties, and confers no rights

Regards,
Mo Lin
Microsoft Support Engineer

 
 
 

Weekday

Post by Humberto Pannefle » Fri, 08 Feb 2002 23:31:27


First of all thank you for the information.  I ran the
Query analyzer with the Set Datefirst statement, but it
didn't do anything.  I checked the dimensions after I
reprocessed them, but the remained the same. Is there
something else I have to do after I set the DateFirst to
1?  

Thank you

Quote:>-----Original Message-----

>Open Query Analyzer and connect to SQL Server,


Quote:>check whether the returned value equals 7. If so,

execute "SET DATEFIRST  
Quote:>1" to force SQL Server to use Monday as the first day of
the week.

>This posting is provided "AS IS" with no warranties, and
confers no rights

>Regards,
>Mo Lin
>Microsoft Support Engineer

>.

 
 
 

Weekday

Post by Mo Lin[M » Thu, 14 Feb 2002 12:00:03


I am not sure whether you have seen my another post. I re-attach it as
below, you may have a  try again:

Hi,

As the method that I provided in the previous post  is connection
dependent, says, If a new connection is made to SQL Server or if the server
is stopped and restarted, the setting of date first will go back.

It is hard to set datefirst from Analysis Service directly. The following I
am introducing a workaround for your reference,

1. In SQL Server Enterprise Manager, create a login with default language
"British_Englisg". (By default, for "us_english" the first day of the week
is Sunday, but for "British_Englisg", the first day of the week is Monday.)

2. Grant the required permissions to it.

3. Using this login ID in cube data source to connect SQL Server.

Then, sales by week will start on Monday.

This posting is provided "AS IS" with no warranties, and confers no rights

Regards,
Mo Lin
Microsoft Support Engineer