You are not logged in.

Dear visitor, welcome to Palo Community Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Vasily

Professional

  • "Vasily" started this thread

Posts: 13

Date of registration: Aug 4th 2011

  • Send private message

1

Monday, May 7th 2012, 8:37pm

Cyle in rule

Hello
How can I compare the values ​​in the two cubes in two different dimensions.
The algorithm is as follows: in the first dimension, I am taking the first element and compare the value with the values ​​at the intersection of all elements in the second dimension, and then take the second value from the first measure and compare again with all the values ​​from the second dimension

Not a very clear description, but in short, to get the result, I use 10 of these rules (because of the number of elements in the measurement of "1-10"), and I would like to make one, because in reality, the number of elements will be much greater.


The rules is next:
['JobValueF'] = IF(PALO.DATA("_122_", "OperXJobs_Cube", !'1-10', "JobName") == PALO.DATA("_122_", "jobsDets", "1", "JobName"), PALO.DATA("_122_", "jobsDets", "1", "JobValue"), CONTINUE())
['JobValueF'] = IF(PALO.DATA("_122_", "OperXJobs_Cube", !'1-10', "JobName") == PALO.DATA("_122_", "jobsDets", "2", "JobName"), PALO.DATA("_122_", "jobsDets", "2", "JobValue"), CONTINUE())
['JobValueF'] = IF(PALO.DATA("_122_", "OperXJobs_Cube", !'1-10', "JobName") == PALO.DATA("_122_", "jobsDets", "3", "JobName"), PALO.DATA("_122_", "jobsDets", "3", "JobValue"), CONTINUE())
.
.
.


I think it's something like a cycle that must be placed in the specified location

['JobValueF'] = IF(PALO.DATA("_122_", "OperXJobs_Cube", !'1-10', "JobName") == PALO.DATA("_122_", "jobsDets", CYCLE, "JobName"), PALO.DATA("_122_", "jobsDets", CYCLE, "JobValue"), CONTINUE())

jjunek

Jedox Team

  • "jjunek" is male

Posts: 58

Date of registration: Sep 16th 2009

Location: Prague

Occupation: PALO OLAP Server architect

  • Send private message

2

Thursday, May 17th 2012, 2:31pm

Hi Vasily,

I'm developing the palo rules engine. Loop support in rules is missing and is not planned for next version.
As I understood your problem, you need to get one of JobValue values from cube jobsDets. In your case for elements 1,2,3...,10 in first dimension into area [*,JobValueF] (not sure from what cube, I suppose from OperXJobs_Cube). Only variable here is !'1-10' (the coordinate within dimension "1-10"). It looks like you are mapping each element of dimension "1-10" into another element of the same or similar dimension. Right?

In this case you can define an attribute (e.g. "mapping") for dimension "1-10", fill the attribute cube and use it for mapping.

['JobValueF'] = PALO.DATA("_122_", "jobsDets", PALO.DATA("_122_","#_1-10","mapping",!'1-10'), "JobValue")
should do what you need

Jiri

Rate this thread