Forum Discussion

laurahoff97's avatar
laurahoff97
Frequent Visitor
1 year ago
Solved

Adding two measurements from different tables

I have two different tables in powerbi pulled in from a database. The first is overall agreements with four columns for different types of cost and each agreement has an alloted amount for hardware/s...
  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi laurahoff97 ,

     

    As per your description, I have created two tables and created relationships for them.

     

    Create measure.

    AgreementTotal = SUM(Agreements[HardwareCost]) + SUM(Agreements[SoftwareCost]) + SUM(Agreements[LaborCost]) + SUM(Agreements[TravelCost])

     

    RecordTotal = SUM(Records[HardwareCost]) + SUM(Records[SoftwareCost]) + SUM(Records[LaborCost]) + SUM(Records[TravelCost])

     

    RemainingAmount = 
    Agreements[AgreementTotal] - 'Agreements'[RecordTotal]

     

     

     

    If your Current Period does not refer to this, please clarify in a follow-up reply.

     

    Best Regards,

    Clara Gong

    If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.