Skip to Content
0
May 29, 2015 at 12:34 PM

if then else Bex Query does not work

14 Views

Hi,

i have a query and I try to achieve a if then else formula.

I have the folowin columns:

A with value 100.00 USD

B with value 0.00 USD

C with value 60.00 USD

D is a fomula: (A+B) - C = 40.00 USD

E = if the else fomula: IF (D < 0) then 0, else D

I tried this fomluar in bex as follows:

(D < 0) * 0 + NOT(D < 0)+ D

The result should be 40.00 USD but I get an error:

Additional elements that do not have the same dimension, such as quantities and amounts or amounts and ratios, are added to element Formula E

A, B and C are values with currency USD. All columns have the same currency.

thanks for your help.