Using dynamic subsets in rules

Post Reply
User avatar
Steve Rowe
Site Admin
Posts: 2417
Joined: Wed May 14, 2008 4:25 pm
OLAP Product: TM1
Version: TM1 v6,v7,v8,v9,v10,v11+PAW
Excel Version: Nearly all of them

Using dynamic subsets in rules

Post by Steve Rowe »

I've split this off this thread.

kielmc said
This is where having the ability to use dynamic subsets on the left side would be extremely beneficial. Look for it in a future release : )
It sounds horrible to me and potentially very "expensive" as I would think that it would require some form of recompile of the rules and feeders if the left hand side of the rule is refers to a changing area too. It also makes me uncomfortable since you are using an object (a subset) which is intended (IMO!) for use to control the order and display of elements, not as a fundamental part of the rule structure.

I'm not sure if kielmc meant this comment in jest or if it's on the roadmap somewhere, I was just wondering if it's something that people think would be useful.
Technical Director
www.infocat.co.uk
User avatar
Alan Kirk
Site Admin
Posts: 6608
Joined: Sun May 11, 2008 2:30 am
OLAP Product: TM1
Version: PA2.0.9.18 Classic NO PAW!
Excel Version: 2013 and Office 365
Location: Sydney, Australia
Contact:

Re: Using dynamic subsets in rules

Post by Alan Kirk »

Steve Rowe wrote:I've split this off this thread.

kielmc said
This is where having the ability to use dynamic subsets on the left side would be extremely beneficial. Look for it in a future release : )
It sounds horrible to me and potentially very "expensive" as I would think that it would require some form of recompile of the rules and feeders if the left hand side of the rule is refers to a changing area too. It also makes me uncomfortable since you are using an object (a subset) which is intended (IMO!) for use to control the order and display of elements, not as a fundamental part of the rule structure.

I'm not sure if kielmc meant this comment in jest or if it's on the roadmap somewhere, I was just wondering if it's something that people think would be useful.
No, I agree with you. Bad idea, bad, bad idea.

One may argue that subsets are part of the metadata, but to my mind there is something fundamentally different about subsets when compared to metadata like cube, dimension and element definitions. (Though less so when compared to, say, attributes which (as David mentioned) can be used in rules definitions.) If you delete a cube or a dimension or an element it destroys the data. However subsets can be (and often are) created and destroyed dynamically and at will, and short of a fundamental change to the architecture I can't see any way of the system being able to stop someone from accidentally or unintentionally destroying a subset which is used in a rule simply because they didn't realise that it was so used. As soon as that happens, the reliability of your output data is toast.

The solution may be to embed the MDX code of the dynamic subset in the rule definition rather than relying on a subset object as such, but I have an inkling that this would be a performance killer the likes of which not seen since Jack Nicholson did The Shining.

But fear not, it'll probably never happen. It would add nothing to promotional demos. :twisted:
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.
lotsaram
MVP
Posts: 3657
Joined: Fri Mar 13, 2009 11:14 am
OLAP Product: TableManager1
Version: PA 2.0.x
Excel Version: Office 365
Location: Switzerland

Re: Using dynamic subsets in rules

Post by lotsaram »

I posted something similar in the original thread but as to the usefulness of this as a feature. Let's have a think from the developer's perspective. ("Developer" in this context could mean IBM software engineer or TM1 developer ...) Subsets may be invisible to rules but rules are quite obviously sensitive to dimension structure and tests of cube values. How different is it really to change the members of a dynamic subset by populating/changing an attribute or some other cube cell value versus changing the results of a conditional test on the RHS of a rule by changing a cell value and thereby changing the calculation definition for the ruled cell in question? Both are event triggered and so presumably can be automated ...

Of course then there's the other potential impact as rules definitions are allocated to cube areas on a one shot first come basis from top to bottom of the rule file. If area statements could change randomly due to data and meta data changes NOT associated with changes to dimension structure then this would surely involve a considerable additional overhead for the server to watch out for such changes and might also invalidate rule priority association due to changes in area definitions. This would be very difficult to make work and would certainly come at a big performance impact.

Although it seems at first glance quite attractive to use a subset for an area statement (as a replacement for a conditional test on the RHS of the equation), it would be interesting to see if this could work in practice..
Post Reply