Hi,
for a calculation i need a measure from an other cube.
I think there are two possible solutions for this, one per rule and one per import from the other cube.
I am not sure which one is the better solution, at the moment i think the rule is a bit faster than the import,
but i dont know if it has some other impact.
Can somebody give a advice which one could be the better solution?
At the moment i would go for the rule.
thx
Rule vs Process which is faster?
- Steve Rowe
- Site Admin
- Posts: 2464
- 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
Re: Rule vs Process which is faster?
Wow this could get as big as "Time : One lump or two?".
Rules are often quicker to write but rarely faster to calculate but the answer is as ever depends.
Until fairly recently TIs had a significant dis-benefit that they would lock the system, generally this is not now the case and usually can be managed anyway.
The USP of rules is that they calculate in real time, so if your source data is changing every minute say and it takes longer than a minute to calculate your down stream calculations then you would need rules (for an extreme example).
You would have to provide significantly more detail about what you exactly what you want to do, how much resource you have on your infrastructure and how frequently your data changes before sensible advice can be given.
Cheers,
Rules are often quicker to write but rarely faster to calculate but the answer is as ever depends.
Until fairly recently TIs had a significant dis-benefit that they would lock the system, generally this is not now the case and usually can be managed anyway.
The USP of rules is that they calculate in real time, so if your source data is changing every minute say and it takes longer than a minute to calculate your down stream calculations then you would need rules (for an extreme example).
You would have to provide significantly more detail about what you exactly what you want to do, how much resource you have on your infrastructure and how frequently your data changes before sensible advice can be given.
Cheers,
Technical Director
www.infocat.co.uk
www.infocat.co.uk
- paulsimon
- MVP
- Posts: 808
- Joined: Sat Sep 03, 2011 11:10 pm
- OLAP Product: TM1
- Version: PA 2.0.5
- Excel Version: 2016
- Contact:
Re: Rule vs Process which is faster?
Hi
Say your calculation only needs to reference a measure in another cube, the classic example being a Price Cube where Price varies by Product but not by Store, with Price being referenced in the Sales cube which has Store and Product with a calculation like Sales = Units * DB( Price Cube ,.... Price).
In this case you can save some space by using a rule as you don't actually need to have Price as a measure in the Sales cube. By comparison, if you use a TI then you need to add a Price measure to the Sales cube and this will need to be populated for every combination of Product and Store. It may be difficult to identify which combinations of Product and Store have Units Sold or will potentially have Units Sold. Therefore another factor to consider is whether the dimensionality of the referenced cube is lower than that of the main cube.
As a general rule of thumb if the calculation needs to be carried out at consolidated levels such as a ratio or average, then a rule will be better.
If data is being pulled in at the base level and the calculation happens there, then a TI or Rule are options.
As Steve said you need to consider how often the source data changes and how much of it changes. If it changes reasonably frequently but only a few values change, eg Prices on only a few Products are updated, then a rule may be more efficient, as with a TI it will be difficult to identify what has changed so you will end up clearing all data in the Sales cube and pushing across all Prices. During this process the data in the Sales cube won't be reliable.
If on the other hand the data in the referenced cube is static, and is only updated overnight, then a TI is an option, and having the source data in the main cube will give faster calculation, although if a rule is still needed eg Sales = Units * Price then I am not sure that you will get that much benefit vs Sales = Units * DB( Price Cube, ...., Price).
One case where I would lean towards TI rather than Rules is for allocations. In my experience users prefer to run allocations and don't actually want the allocated figures to change immediately as they would with a rule. The use of a TI also gets past the issue of over-feeding which is difficult to avoid with a rule based allocation.
Regards
Paul Simon
Say your calculation only needs to reference a measure in another cube, the classic example being a Price Cube where Price varies by Product but not by Store, with Price being referenced in the Sales cube which has Store and Product with a calculation like Sales = Units * DB( Price Cube ,.... Price).
In this case you can save some space by using a rule as you don't actually need to have Price as a measure in the Sales cube. By comparison, if you use a TI then you need to add a Price measure to the Sales cube and this will need to be populated for every combination of Product and Store. It may be difficult to identify which combinations of Product and Store have Units Sold or will potentially have Units Sold. Therefore another factor to consider is whether the dimensionality of the referenced cube is lower than that of the main cube.
As a general rule of thumb if the calculation needs to be carried out at consolidated levels such as a ratio or average, then a rule will be better.
If data is being pulled in at the base level and the calculation happens there, then a TI or Rule are options.
As Steve said you need to consider how often the source data changes and how much of it changes. If it changes reasonably frequently but only a few values change, eg Prices on only a few Products are updated, then a rule may be more efficient, as with a TI it will be difficult to identify what has changed so you will end up clearing all data in the Sales cube and pushing across all Prices. During this process the data in the Sales cube won't be reliable.
If on the other hand the data in the referenced cube is static, and is only updated overnight, then a TI is an option, and having the source data in the main cube will give faster calculation, although if a rule is still needed eg Sales = Units * Price then I am not sure that you will get that much benefit vs Sales = Units * DB( Price Cube, ...., Price).
One case where I would lean towards TI rather than Rules is for allocations. In my experience users prefer to run allocations and don't actually want the allocated figures to change immediately as they would with a rule. The use of a TI also gets past the issue of over-feeding which is difficult to avoid with a rule based allocation.
Regards
Paul Simon