Dynamic Subset

Post Reply
lax9
Posts: 9
Joined: Thu Apr 12, 2018 9:51 pm
OLAP Product: TM1
Version: 10.2.2
Excel Version: 2016

Dynamic Subset

Post by lax9 » Tue Jul 17, 2018 4:05 pm

Hi All,


Getting the below error while running TI:

Error: Epilog procedure line (412): Could not create dynamic subset:
expression:
{TM1FILTERBYLEVEL( {TM1DRILLDOWNMEMBER( {[Account PCR].[DLR_REC_NACD2 DEALER RECEIVABLES - NACD (Cat Sales Inc) on LM Books] }, ALL, RECURSIVE ) },0 )}

Please let me know how to resolve this?

Thank you!

Edward Stuart
Community Contributor
Posts: 220
Joined: Tue Nov 01, 2011 10:31 am
OLAP Product: TM1
Version: All
Excel Version: All
Location: Manchester
Contact:

Re: Dynamic Subset

Post by Edward Stuart » Tue Jul 17, 2018 4:37 pm

What happens when you input the MDX into an expression window and run it manually?

Wim Gielis
MVP
Posts: 1748
Joined: Mon Dec 29, 2008 6:26 pm
OLAP Product: TM1
Version: PAL 2.0
Excel Version: 2016
Location: Brussels, Belgium
Contact:

Re: Dynamic Subset

Post by Wim Gielis » Tue Jul 17, 2018 8:47 pm

For me it works when I change the dimension name and the (consolidated) element name.

As Edward asked for, what happens if you do this in the Subset Editor of the dimension 'Account PCR' ?

Does the consolidated element have level 0 descendants ? Related to this, what happens if you use the undocumented argument in the function 'SubsetCreateByMDX' whereby adding the dimension name allows the subset to be empty ?

If all of this does not work, please provide a screenshot of this Subset Editor with the expression, where the dimension name and element name are clearly visible.
Best regards,

Wim Gielis

Excel Most Valuable Professional, 2011-2014
http://www.wimgielis.com ==> 105 TM1 articles and a lot of custom code
Newest blog article: Looping over input files

Mark RMBC
Regular Participant
Posts: 154
Joined: Tue Sep 06, 2016 7:55 am
OLAP Product: TM1
Version: 10.1.1
Excel Version: Excel 2010

Re: Dynamic Subset

Post by Mark RMBC » Wed Jul 18, 2018 9:15 am

I would say the problem is with the naming of the element, the parentheses in the name, i.e. (Cat Sales Inc) are causing the mdx to break.

Can you try the following and see if it works:

Code: Select all

{TM1FILTERBYLEVEL( {TM1DRILLDOWNMEMBER( {StrToMember("[Account PCR].[DLR_REC_NACD2 DEALER RECEIVABLES - NACD (Cat Sales Inc) on LM Books]") }, ALL, RECURSIVE ) },0 )}
cheers, Mark

Wim Gielis
MVP
Posts: 1748
Joined: Mon Dec 29, 2008 6:26 pm
OLAP Product: TM1
Version: PAL 2.0
Excel Version: 2016
Location: Brussels, Belgium
Contact:

Re: Dynamic Subset

Post by Wim Gielis » Wed Jul 18, 2018 11:18 am

Mark RMBC wrote:
Wed Jul 18, 2018 9:15 am
I would say the problem is with the naming of the element, the parentheses in the name, i.e. (Cat Sales Inc) are causing the mdx to break.

Can you try the following and see if it works:

Code: Select all

{TM1FILTERBYLEVEL( {TM1DRILLDOWNMEMBER( {StrToMember("[Account PCR].[DLR_REC_NACD2 DEALER RECEIVABLES - NACD (Cat Sales Inc) on LM Books]") }, ALL, RECURSIVE ) },0 )}
cheers, Mark
Hi Mark,

In PA 2.0.5 I cannot reproduce it. It works as expected.
01.png
01.png (17.6 KiB) Viewed 143 times
Best regards,

Wim Gielis

Excel Most Valuable Professional, 2011-2014
http://www.wimgielis.com ==> 105 TM1 articles and a lot of custom code
Newest blog article: Looping over input files

Mark RMBC
Regular Participant
Posts: 154
Joined: Tue Sep 06, 2016 7:55 am
OLAP Product: TM1
Version: 10.1.1
Excel Version: Excel 2010

Re: Dynamic Subset

Post by Mark RMBC » Wed Jul 18, 2018 12:08 pm

Hi Wim,

in 10.1 I was getting an empty subset, but when I used StrtoMember or used the original mdx but without the name containing parentheses it returned the correct elements. I say was because I just tested it again and now it appears to be working!

I might be going mad!

Post Reply