dbTalk Databases Forums  

access to one more cube?

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


Discuss access to one more cube? in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Word 2003 memory Leakage
 
Posts: n/a

Default access to one more cube? - 09-26-2005 , 10:02 AM






Hi,

I would like to use lookupcube to access to one more cube. I could not
specify time range in lookupcube functions.


the following is not working. If I just specify a year (2002), it works.

with
MEMBER [Measures].[ManHours] AS
'LookupCube("Cube_Extra",
"(" + "[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[2]:
[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[12]"
+ ", [Measures].[manHoursWorkedTotal])"
)
'

thanks,

Guangming

Reply With Quote
  #2  
Old   
mike
 
Posts: n/a

Default RE: access to one more cube? - 09-27-2005 , 12:25 PM






you'll need to be referencing the time dimension member of the cube you are
currently in ( let's say cube [Current Cube] that has a time dimension like
this [Time].[CurrentMember ) and hopefully both cubes have the same naming
for the time dimension:

so your calc should look something like this:

MEMBER [Measures].[ManHours] AS '
LookupCube( "Cube_Extra",
"(" + MemberToString([Time].CurrentMember)
+ ", [Measures].[manHoursWorkedTotal])"
)
'

"Word 2003 memory Leakage" wrote:

Quote:
Hi,

I would like to use lookupcube to access to one more cube. I could not
specify time range in lookupcube functions.


the following is not working. If I just specify a year (2002), it works.

with
MEMBER [Measures].[ManHours] AS
'LookupCube("Cube_Extra",
"(" + "[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[2]:
[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[12]"
+ ", [Measures].[manHoursWorkedTotal])"
)
'

thanks,

Guangming

Reply With Quote
  #3  
Old   
Word 2003 memory Leakage
 
Posts: n/a

Default RE: access to one more cube? - 09-27-2005 , 04:31 PM



thank you very much,

I am working in sql server 2005 beta 2. I put all fact tables in one cube,
and this solved the problem. I can set the right time dimensions to all fact
tables. Then I get the measures from each fact tables all sliced by the time
specified.

It is similar to a join in SQL. Is there a way to join two cubes rather than
specifying time dimensions to each fact table.

Guangming

"mike" wrote:

Quote:
you'll need to be referencing the time dimension member of the cube you are
currently in ( let's say cube [Current Cube] that has a time dimension like
this [Time].[CurrentMember ) and hopefully both cubes have the same naming
for the time dimension:

so your calc should look something like this:

MEMBER [Measures].[ManHours] AS '
LookupCube( "Cube_Extra",
"(" + MemberToString([Time].CurrentMember)
+ ", [Measures].[manHoursWorkedTotal])"
)
'

"Word 2003 memory Leakage" wrote:

Hi,

I would like to use lookupcube to access to one more cube. I could not
specify time range in lookupcube functions.


the following is not working. If I just specify a year (2002), it works.

with
MEMBER [Measures].[ManHours] AS
'LookupCube("Cube_Extra",
"(" + "[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[2]:
[Dim_Time].[Year - Quarter - Month -
actualDate].[Year].&[2002].&[12]"
+ ", [Measures].[manHoursWorkedTotal])"
)
'

thanks,

Guangming

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.