Hi There,
Is there a way to find out if a member exists in a set in MDX other than using STRTOSET?
I do not want to use: (since STRTOSET is expensive and sort of deprecated)
IIF( STRTOSET(@A, CONSTRAINED).Count = 1, STRTOSET(@A, CONSTRAINED), [Area].currentmember ) )
I tried using RANK, ORDER or Compare MemberName to IsEmpty or null, but did not get anywhere.
So, lets say, I have a set that has members 1 through 5 in a set called 'S'
IIF(([s].&[1].Member_Name = ""),1,2) - works
IIF(([s].&[15].Member_Name
= ""),1,2) - gives #VALUE! - so if I try to access a member that is not there, what is returned actually? Its not NULL since I tried IIF(([s].&[15].Member_Name
is NULL),1,2) and still got #VALUE!
Similarly, IIF(Rank([s].&[15].Member_
Name) >0),1,2) didn't work and gave #VALUE!.
Any help is appreciated.
Thanks
Start Free Trial