dbTalk Databases Forums  

Question about using Shared Dimensions

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


Discuss Question about using Shared Dimensions in the microsoft.public.sqlserver.olap forum.



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

Default Question about using Shared Dimensions - 10-05-2005 , 05:19 PM






We have several cubes which use the same shared dimensions, mostly the Date
dimension.

Our cubes build every hour - the largest cube taking around six hours to
rebuild. If that cube needs to go offline for a rebuild, how will this
affect the other cubes (they'll still be processing every hour) which use
the same shared dimension?

Cube uptime is of utmost importance. Taking all cubes offline so one can be
processed won't fly. I'd have to resort to using private dimensions which I
really don't want to do.

Thanks guys!




Reply With Quote
  #2  
Old   
Darren Gosbell
 
Posts: n/a

Default Re: Question about using Shared Dimensions - 10-06-2005 , 03:30 AM






If you are only adding to the dimensions (not moving existing members
around in the hierarchy) you only need to do an incremental process on
the dimension which will not invalidate the cube structure, so the cube
will not go offline.

Cubes are only taken "offline" when you do a full process a shared
dimension.

If you are able to do this your cubes should never have to go offline.
AS is designed so that the cubes will remain "query-able" even while
they are being processed. Then, once processing is finished the cubes
will flick over to the updated data.

Even if you do need to do a full process on the dimensions, it is
possible to process them within a "transaction" and hence leave the
existing data accessible while the processing is running.

--
Regards
Darren Gosbell [MCSD]
<dgosbell_at_yahoo_dot_com>
Blog: http://www.geekswithblogs.net/darrengosbell

In article <ua#PkrfyFHA.1040 (AT) TK2MSFTNGP14 (DOT) phx.gbl>, jesperzz (AT) hotmail (DOT) com
says...
Quote:
We have several cubes which use the same shared dimensions, mostly the Date
dimension.

Our cubes build every hour - the largest cube taking around six hours to
rebuild. If that cube needs to go offline for a rebuild, how will this
affect the other cubes (they'll still be processing every hour) which use
the same shared dimension?

Cube uptime is of utmost importance. Taking all cubes offline so one can be
processed won't fly. I'd have to resort to using private dimensions which I
really don't want to do.

Thanks guys!





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

Default Re: Question about using Shared Dimensions - 10-06-2005 , 11:31 AM



I meant offline in that we made a structural change to the cube which would
require a full reprocessing.

We incrementally update all our dimensions.


"Darren Gosbell" <xxx (AT) xxx (DOT) com> wrote

Quote:
If you are only adding to the dimensions (not moving existing members
around in the hierarchy) you only need to do an incremental process on
the dimension which will not invalidate the cube structure, so the cube
will not go offline.

Cubes are only taken "offline" when you do a full process a shared
dimension.

If you are able to do this your cubes should never have to go offline.
AS is designed so that the cubes will remain "query-able" even while
they are being processed. Then, once processing is finished the cubes
will flick over to the updated data.

Even if you do need to do a full process on the dimensions, it is
possible to process them within a "transaction" and hence leave the
existing data accessible while the processing is running.

--
Regards
Darren Gosbell [MCSD]
dgosbell_at_yahoo_dot_com
Blog: http://www.geekswithblogs.net/darrengosbell

In article <ua#PkrfyFHA.1040 (AT) TK2MSFTNGP14 (DOT) phx.gbl>, jesperzz (AT) hotmail (DOT) com
says...
We have several cubes which use the same shared dimensions, mostly the
Date
dimension.

Our cubes build every hour - the largest cube taking around six hours to
rebuild. If that cube needs to go offline for a rebuild, how will this
affect the other cubes (they'll still be processing every hour) which
use
the same shared dimension?

Cube uptime is of utmost importance. Taking all cubes offline so one can
be
processed won't fly. I'd have to resort to using private dimensions which
I
really don't want to do.

Thanks guys!







Reply With Quote
  #4  
Old   
Darren Gosbell
 
Posts: n/a

Default Re: Question about using Shared Dimensions - 10-07-2005 , 05:24 PM



In article <uoFItNpyFHA.2644 (AT) TK2MSFTNGP09 (DOT) phx.gbl>, jesperzz (AT) hotmail (DOT) com
says...
Quote:
I meant offline in that we made a structural change to the cube which would
require a full reprocessing.

We incrementally update all our dimensions.

In that case it is still possible, but I think it will involve a bit of
custom code. I think the mention of the Date dimension threw me, as the
structure of a date dimension does not usually change over time, in most
cases you are just adding members.

The put together the following DSO code in VBA (I used Excel as a quick
and dirty test bed). It should run in VB6 or .Net pretty much unchanged
as long as you include a reference to the DSO library.


'\\ ================================================== ===
'\\ Process a Shared Dimension and All dependant cubes.
'\\ ================================================== ===
Sub Process()
Dim svr As DSO.Server
Dim mdDb As DSO.MDStore
Dim dimTime As DSO.Dimension
Dim mdCube As DSO.MDStore
Dim sDimName As String
Dim sServer as String
Dim sDatabase as String

'\\ Update the following variables
'\\ ========================================
sDimName = "Time" '<<< -- Dimension to Process
sServer = "DARREN01" '<<< Server Name <<<
sDatabase = "Foodmart 2000" '<<< Database Name <<<


Set svr = New DSO.Server
svr.Connect sServer
Set mdDb = svr.MDStores(sDatabase)

Set dimTime = mdDb.Dimensions(sDimName)

'\\ Start a new dso Transaction
mdDb.BeginTrans

On Error GoTo ErrorHandler

'\\ Process the Dimension
dimTime.Process processFull

'\\ Find each cube that uses the shared dimension
'\\ and re-process them
For Each mdCube In mdDb.MDStores
If mdCube.Dimensions.Find(sDimName) Then
mdCube.Process processFull
End If
Next

'\\ Commit the Transaction
mdDb.CommitTrans

GoTo Finish

ErrorHandler:
'\\ On Error - Rollback the transaction
mdDb.Rollback

Finish:
svr.CloseServer

End Sub

--
Regards
Darren Gosbell [MCSD]
<dgosbell_at_yahoo_dot_com>
Blog: http://www.geekswithblogs.net/darrengosbell


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.