Problem to do a DB based in a picklist value.
Posted: Thu Mar 16, 2017 2:06 pm
Admin Note : Moved to the correct forum, please post in the correct forum, ty
Dear friends, I have two cubes to calculate the contracts costs of my company and I am having a little problem to do a simple DB to consolidate the informations.
First Cube CONTRACTS_ADJUSTMENT with dimensions:
ALL.D.YEAR
ALL.D.MONTH
ALL.D.CONTRACT
ALL.M.ADJUSTMENT: with a input of the adjustment (%) and a total value of contract who have to come from "Contracts_Value".
Second Cube CONTRACTS_VALUE
ALL.D.YEAR
ALL.D.MONTH
ALL.D.ACCOUNT
ALL.M.VALUE: with a input value of contract($) and a picklist cell who contains the CONTRACTs dimension.
My problem is, I can't do the DB to get the value of CONTRACT_VALUE to CONTRACT_ADJUSTMENT (because the picklist is not a dimension). Can some one help me?
Thats what I am trying:
['value'] = N:
IF (DB('CONTRACTS_VALUE',
!ALL.D.YEAR,
!ALL.D.MONTH,
'Total Accounts',
'Contract') @= !ALL.D.CONTRACT,
DB('CONTRACTS_VALUE',
!ALL.D.YEAR,
!ALL.D.MONTH
'Total Accounts',
'Value'), 0);
But the IF condition returns false all time (maybe because the contract name is in the level 0 of the ALL.D.ACCOUNT, and I am using the 'Total Accounts').
Anyone know a better way to do that?
Dear friends, I have two cubes to calculate the contracts costs of my company and I am having a little problem to do a simple DB to consolidate the informations.
First Cube CONTRACTS_ADJUSTMENT with dimensions:
ALL.D.YEAR
ALL.D.MONTH
ALL.D.CONTRACT
ALL.M.ADJUSTMENT: with a input of the adjustment (%) and a total value of contract who have to come from "Contracts_Value".
Second Cube CONTRACTS_VALUE
ALL.D.YEAR
ALL.D.MONTH
ALL.D.ACCOUNT
ALL.M.VALUE: with a input value of contract($) and a picklist cell who contains the CONTRACTs dimension.
My problem is, I can't do the DB to get the value of CONTRACT_VALUE to CONTRACT_ADJUSTMENT (because the picklist is not a dimension). Can some one help me?
Thats what I am trying:
['value'] = N:
IF (DB('CONTRACTS_VALUE',
!ALL.D.YEAR,
!ALL.D.MONTH,
'Total Accounts',
'Contract') @= !ALL.D.CONTRACT,
DB('CONTRACTS_VALUE',
!ALL.D.YEAR,
!ALL.D.MONTH
'Total Accounts',
'Value'), 0);
But the IF condition returns false all time (maybe because the contract name is in the level 0 of the ALL.D.ACCOUNT, and I am using the 'Total Accounts').
Anyone know a better way to do that?