Forum Discussion

Saloni's avatar
Saloni
Icon for Helper I rankHelper I
9 years ago
Solved

DAX for Measures

Why doesn't the calculated measure indentify tables and columns when I use the Divide function? Only calculated columns identify tables and columns with the divide function. Any specific reason?

  • Because measures require some kind of aggregation function be used; calculated columns have a row context so it knows which row you are referring to.  

     

    With measures you can do this:

     

    Measure = DIVIDE ( SUM ( Table(Column), SUM (Table(Column2) )  

     

    but not

     

    Measure = DIVIDE ( Table(Column), Table(Column2) )

    because Dax engine can't figure out what rows you are referring to in the measure.

2 Replies

  • Because measures require some kind of aggregation function be used; calculated columns have a row context so it knows which row you are referring to.  

     

    With measures you can do this:

     

    Measure = DIVIDE ( SUM ( Table(Column), SUM (Table(Column2) )  

     

    but not

     

    Measure = DIVIDE ( Table(Column), Table(Column2) )

    because Dax engine can't figure out what rows you are referring to in the measure.

  • dearwatson's avatar
    dearwatson
    Icon for Continued Contributor rankContinued Contributor

    Hi Saloni,

     

    Not sure I understand your question, can you provide an example?

     

    Cheers

    Greg