Hi,
Take foodmart sales cube as an example, I want to find out store sizes that are bigger than 35000. I have tried.
1. select filter([Store Size in SQFT].[Store Sqft].members, STRTOVALUE([Store Size in SQFT].currentmember.name) > 35000) on columns from sales
Output: An MDX expression was expected. An empty expression was specified.
2.
select filter([Store Size in SQFT].[Store Sqft].members, [Store Size in SQFT].currentmember.name > '35000')
on columns from sales
Output: lexicological comparison, not what I want.
3.
select filter([Store Size in SQFT].[Store Sqft].members, [Store Size in SQFT].currentmember > 30000) on columns from sales
Output: comparing with default measure instead.
I guess I am still having the SQL mindset. Any help is really appreciated.
Hi
you should use function Val in order to convert string property into number.
select
filter([Store Size in SQFT].[Store Sqft].members, Val([Store Size in SQFT].currentmember.name) > 35000)
on columns
from sales
No comments:
Post a Comment