Forum Discussion

JohnD2's avatar
JohnD2
Frequent Visitor
9 years ago
Solved

Multiplying calculated column values

Hi, i have created two calculated column in a table.   Now i want to multiply those values, but i get a circular error. It is a simple Price * Quantity multiplication, where the values in the row ...
  • Daniil's avatar
    9 years ago

    Would you mind sharing the formulas used to calculate Price and Quantity? Multiplying two calculated columns should not give you an error by itself.

     

    In any case, you can try using variables for the Result column, like so:

    Result =
    VAR PriceVar = (your Price column formula goes here)
    VAR QuantityVar = (your Quantity column formula goes here)
    RETURN PriceVar * QuantityVar

    This way, the Result column will not depend on either Quantity or Price columns, so if you don't strictly need them, you can get rid of them and save memory.

  • sdjensen's avatar
    9 years ago

    JohnD2 - do you really need it to be a calculated column? what happens if just calculate as a measure instead like measure = SUMX( tablename, tablename[Price] * tablename[Quantity]) ?