Forum Discussion

NishPatel's avatar
NishPatel
Resolver II
5 years ago
Solved

Yearly Calculated Measure

Hi,   I have below two tables. The rate in Table A is (Yearly $ / Yearly Hours). I also have another Table B where employees have scheduled labor $'s. Cost in Table B = (Labor $ * Lookup Rate in Ta...
  • Jihwan_Kim's avatar
    5 years ago

    Hi, NishPatel 

    Please try to use the below measure.

     

    Cost =
    SUMX (
    TableB,
    TableB[Labor $]
    * LOOKUPVALUE ( TableA[Rate], TableA[Fiscal Year], TableB[Fiscal Year] )
    )

     

    Hi, My name is Jihwan Kim.

    If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

  • Anonymous's avatar
    Anonymous
    5 years ago

    Hi NishPatel ,

    You can create a calculated column as below:

    Column = 
    VAR _rate =
        CALCULATE (
            MAX ( 'A'[Rate] ),
            FILTER ( 'A', 'A'[Fiscal Year] = 'B'[Fiscal Year] )
        )
    RETURN
        'B'[Labor $] * _rate

    Best Regards