dbTalk Databases Forums  

Time Dimensions down to the hour?

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Time Dimensions down to the hour? in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Marty
 
Posts: n/a

Default Time Dimensions down to the hour? - 11-14-2006 , 11:52 AM






I used the wizard to create a time table but was wondering if there is a way
to get it the hour instead of just the date level?
--
Marty

Reply With Quote
  #2  
Old   
Jesse O.
 
Posts: n/a

Default Re: Time Dimensions down to the hour? - 11-15-2006 , 03:11 PM






Not sure, however I use a separate Hour dimension which has values from
0-23.

I prefer this approach since I can compare the curves day over day.


"Marty" <Marty (AT) discussions (DOT) microsoft.com> wrote

Quote:
I used the wizard to create a time table but was wondering if there is a
way
to get it the hour instead of just the date level?
--
Marty



Reply With Quote
  #3  
Old   
Marty
 
Posts: n/a

Default Re: Time Dimensions down to the hour? - 11-15-2006 , 04:07 PM



That is what I am trying to get to. I need to be able to compare what happen
between 10:00 a.m. and 11:00a.m. and compare it to 11:00 a.m. and 12:00p.m.
--
Marty


"Jesse O." wrote:

Quote:
Not sure, however I use a separate Hour dimension which has values from
0-23.

I prefer this approach since I can compare the curves day over day.


"Marty" <Marty (AT) discussions (DOT) microsoft.com> wrote in message
news:E70E8A7B-AD2F-4004-A38F-2BF203E86ACB (AT) microsoft (DOT) com...
I used the wizard to create a time table but was wondering if there is a
way
to get it the hour instead of just the date level?
--
Marty




Reply With Quote
  #4  
Old   
Julius Concepcion
 
Posts: n/a

Default Re: Time Dimensions down to the hour? - 11-18-2006 , 04:28 AM



You can create a named query to simply build an hour dimension using
something similar to this:

--------------- start ----------------
select 1 as sort_order_key, '1 am' as hour
union
select 2, '2 am'
union
.......
select 23, '12 pm'
------------- end -----------------

Create an Hour_Dim from this.

Then, in your fact table convert your datetime field to hour only as
another column (named query makes this easy). Now you can join the hour
dimension to this field.







On Nov 15, 2:07 pm, Marty <M... (AT) discussions (DOT) microsoft.com> wrote:
Quote:
That is what I am trying to get to. I need to be able to compare what happen
between 10:00 a.m. and 11:00a.m. and compare it to 11:00 a.m. and 12:00p.m.
--
Marty



"Jesse O." wrote:
Not sure, however I use a separate Hour dimension which has values from
0-23.

I prefer this approach since I can compare the curves day over day.

"Marty" <M... (AT) discussions (DOT) microsoft.com> wrote in message
news:E70E8A7B-AD2F-4004-A38F-2BF203E86ACB (AT) microsoft (DOT) com...
I used the wizard to create a time table but was wondering if there is a
way
to get it the hour instead of just the date level?
--
Marty- Hide quoted text -- Show quoted text -


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.