Page 1 of 1

Nested Feeders

Posted: Fri Apr 18, 2014 1:54 pm
by dharav
Hello All

I have two cubes Cube ABC and Cube PQR

Cube ABC (dim):

dim1
dim2
dim3
dim4
dim5

Cube PQR (dim):
dim1
dim6
dim3

The elements in dim3
Agts
Company

The rule in the Cube PQR Cube:
['agnts']=DB('cubeabc',!dim1,'agts');

and in cube abc feeders for cube pqr rules (It throws an error for below feeders:Element name ambiguous 'agts' ['agts']=>db('cubepqr',!dim1,'agts');)

['agts']=>db('cubepqr',!dim1,'agts');

I know thats not a right approach as i have to slice each member which are not link with each other.

Could please let me know the better way to manage this problem:

Re: Nested Feeders

Posted: Fri Apr 18, 2014 3:28 pm
by java_to_tm1
Does any of the other dimensions in Cube ABC have an element called 'Agts'?

The error about ambiguous element is telling you that it is not able to identify which agts element to feed from:

Code: Select all

['agts']=>db('cubepqr',!dim1,'agts');
should be corrected as (if I'm understanding you right that you wanto use dim3's element Agts)

Code: Select all

['dim3:agts']=>db('cubepqr',!dim1,'agts');
But that is only PART of the problem:
the complete problem is that you are not referencing the cubes correctly.
CubePQR has 3 dims, but you mention only two of them in the feeder: !dim1, and the 'Agts' element.
You need to identify which element in dim 6 you want to feed and refer it in the feeder.

Code: Select all

['dim3:agts']=>db('cubepqr',!dim1, 'specific element in dim6' , 'agts');
If all elements in dim 6 need to be fed you should feed the 'total' element in dim 6 (if it has a 'total of...' element, or feed each element of dim6 individually).

You'll also find that your rule in cubePQR that references cubeABC is wrong for the same reason as above: It doesnt reference all the dims in cubeABC.
The rule references only 2 dims out of 6.