rozef wrote:Edit:
Alright, maybe I get lucky because I tried it many times and it have been always faster with MDX then without.
I will try it more harder if I have time for this.
By all means, please share any evidence to the contrary...
I felt like killing time over lunch and ran some really simple tests via TI to try and re-validate some of what's been raised here (since we're already way off topic).
My data (totally made-up sample data set - designed to be fairly large in order to make sure any tests/timing could be measured):
- Simple cube with 4 dimensions: Scenarios (3 members), Time Periods (12 members), Centers (2,600 members), Accounts (400,000 members).
- One scenario in the cube is populated with about 62,000,000 values
- The account dimension has a subset, based on a filter by expression, that results in 400 members in the subset. A version of that subset is saved as a public, dynamic subset and another is saved as a public, static subset. Both are ultimately identical in terms of the members they contain.
- All tests done in TM1 9.5.2 (no hotfixes applied, I don't think)
First test: Create a new dimension and populate an attribute in it based on a TM1 Subset data source
I realize you and others know this to be a known problem with dynamic subsets as data sources, but wanted to quantify it.
Populate a new dimension and an attribute in that dimension from my Static subset: 0 seconds (couldn't really measure the time).
Populate a new dimension and an attribute in that dimension from my Dynamic subset:
10-11 minutes
Not too surprising if you've ever run into this before - incidentally, it appeared that updating the attribute value (a data change) was primarily the issue because if I remove that and only add elements to the new dimension (a metadata change) the execution times between static vs dynamic are similar. I'm not sure I had made that distinction before since I've long since abandoned ever using dynamic subsets as data sources, but thought I'd mention it.
Second test: Copy data in one scenario to a different scenario based on views using a subset to filter data being exported
In this case, I decided not to even bother dynamically creating/destroying views or subsets (which have the potential to cause additional server/object locking issues, incidentally) - I just used one of two public views:
1) View export based on the earlier static subset for a static scenario.
2) View export based on the earlier dynamic subset for a static scenario.
In each process I had a view that zeroed out the target scenario (all static subsets), which was completed in the Prolog.
The results (repeated 5 times):
Copy scenario data using export view with Static subset: 30-31 seconds each run
Copy scenario data using export view with Dynamic subset: 31-33 seconds each run
So, this obviously isn't the most scientific test and testing equipment (my own computer) in the world, but at the very least there's nothing here that would suggest the dynamic subset approach is more efficient/faster. NOTE: Any time measurements here were gathered by capturing a time stamp in the Prolog and another in the Epilog and writing that out via ASCIIOUTPUT to get a start/end time.
rozef wrote:By the way, I still think these cases of slowing down can only happend in large servers or with many interactions because I never heard about it.
Just because you haven't heard about something doesn't mean it isn't true or uncommon.
And I think this is why you've gotten some grief here (albeit maybe not always in the nicest of tones, I'll grant you, but then you have been pretty strong in your assertions to the contrary). I, and I'm sure David, Lotsa and a number of others on the TM1 forum have worked with and come across many models that, as developed, work wonderfully with one or a couple users at any given time. Not all of these models are not extremely intricate or large, but once you get any significant number of concurrent users hitting that model and updating values (especially), reading views at a consolidated level, running TI processes, etc at the same time that performance can go downhill very quickly if you don't design your TM1 model to avoid some of those potential pitfalls.
And this is the crucial point here - if you think only about how an individual process runs in isolation, you are ignoring a bigger part of the overall performance picture in many TM1 applications. Saying that "MDX subsets are always faster then static subsets" is a dangerous (and until proven otherwise, false) statement without the proper context for less-informed users reading the forum. There are broader implications with regards to server/object locking, in particular, when you are dealing with things like high concurrency planning applications where the choice of dynamic vs static subsets can be a crucial one in designing certain application elements. In the case of the original poster and in many smaller, or more static reporting-type/read-only, TM1 applications, the choice of dynamic vs static subsets may be of little consequence. I use dynamic subsets all the time because they are incredibly useful and efficient to create, but often there are situations where I'm trying to squeeze out better performance/improve concurrency and I may adjust how dynamic subsets are being used in that application. I wish that weren't the case, but it is and I don't think you'll find too many at IBM or on this forum that will disagree.
Regards,
Mike