SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


MDX 101 Question


MDX 101 Question

Author
Message
dmcquilken
dmcquilken
SSC Journeyman
SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)

Group: General Forum Members
Points: 92 Visits: 63
Anyone know why the following doesnt work?

SELECT
{
[DimX].[DimId].Members,
[DimX].[DimId].currentmember.properties("value" )
} ON ROWS,
[Measures].[Mea_1] ON COLUMNS
FROM Measures

This keeps throwing the following exception:

Query (2, 2) The function expects a tuple set expression for the 2 argument. A string or numeric expression was used.


As an aside, is a way to maximize the performance of querying for member properties?

Thanks in advance
robinrai3
robinrai3
Mr or Mrs. 500
Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)

Group: General Forum Members
Points: 570 Visits: 367
check this out :

MEMBER MyValue as 'DimX].[DimId].currentmember.properties("value")'
SELECT
{[DimX].[DimId].Members, MyValue} ON ROWS,
[Measures].[Mea_1] ON COLUMNS
FROM MyCube

also check out http://www.mdxsamples.com/ ...on why using properties is slow (see bottom para)
dmcquilken
dmcquilken
SSC Journeyman
SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)SSC Journeyman (92 reputation)

Group: General Forum Members
Points: 92 Visits: 63
robinrai3 (5/14/2013)
check this out :

MEMBER MyValue as 'DimX].[DimId].currentmember.properties("value")'
SELECT
{[DimX].[DimId].Members, MyValue} ON ROWS,
[Measures].[Mea_1] ON COLUMNS
FROM MyCube

also check out http://www.mdxsamples.com/ ...on why using properties is slow (see bottom para)


Thanks for responding.

I see how you declare the member before the select. Is it possible to do this inline, after the select?
robinrai3
robinrai3
Mr or Mrs. 500
Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)Mr or Mrs. 500 (570 reputation)

Group: General Forum Members
Points: 570 Visits: 367
hi ,

I've been down the mineshaft on trying to learn mdx coming from a TSQL background ...its been one step foward, 3 back all the time...a real ball ache. Don't know why it does not work inline ...but works when declared as a member. One thing I've found is that doing all the donkey work in using declared sets and members seems to work in situations when you would think in line it would work as well

I'm no guru..but contact me again if you need further help...lets share the knowledge...
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search