Subsetcreatebymdx

Post Reply
manu0521
Posts: 124
Joined: Wed Nov 26, 2014 8:32 pm
OLAP Product: IBM TM1, Planning Analytics
Version: PA 2.0.5
Excel Version: 2016

Subsetcreatebymdx

Post by manu0521 » Sun Jun 06, 2021 1:04 am

Hi ,

I am trying to create a subsetcreatebymdx with below code
vMdx= '{TM1FILTERBYLEVEL( {TM1SUBSETALL( [Price Range] )}, 0)}';
SubsetcreatebyMdx(subsetname,vmdx,0);

But its giving me an error unable to register the subset .
I want to use it for zero out in prolog .

But then I did a similar

SUBSETMDXSET(vDimension,vSourceSubset, vMdx );
SUBSETMDXSET( vDimension,vSourceSubset,'' );


And then did a ascii output and it wrote the values for price range n elements,

Why is my SubsetcreatebyMdx having issues here and can i not use it or when should i use it .

Thanks,

manu0521
Posts: 124
Joined: Wed Nov 26, 2014 8:32 pm
OLAP Product: IBM TM1, Planning Analytics
Version: PA 2.0.5
Excel Version: 2016

Re: Subsetcreatebymdx

Post by manu0521 » Sun Jun 06, 2021 1:09 am

I think i got it ,
I have to destroy the subset and then use subssetcreatemdx .
Which one is better if i have to just use for zerout .
subsetcreatebymdx or SUBSETMDXSET

Wim Gielis
MVP
Posts: 2711
Joined: Mon Dec 29, 2008 6:26 pm
OLAP Product: TM1, Jedox
Version: PAL 2.0.8
Excel Version: Microsoft 365
Location: Brussels, Belgium
Contact:

Re: Subsetcreatebymdx

Post by Wim Gielis » Sun Jun 06, 2021 2:02 am

Use temporary subsets and you will have a lot less headaches.
Best regards,

Wim Gielis

Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 117 TM1 articles and a lot of custom code
Newest blog article: Avoid circular references https://github.com/wimgielis

Post Reply