Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

How to sum two cards

Dear all, 

is it possible, to sum two cards? I have two cards, each one representing result from table. 

- Card A sums a column from table A with date and personal filters

- Card B sums a column from table B with different date and personal filters

Filters from table A dont interact with filters from table B. That is correct. So at the end, after applying all the filters, I have result A and result B (and they change, when I change the filters), that I see on the cards A and B. Is it possible to make a card, that will sum results A and B? I tryed to make a metrics, that sums the column A and B, but it takes all the filters. I need to apply filters separately and then sum the two cards. Like in Excel, when you make two calculations and the sum up the two results. Is it possible?

Thank you!

 

  • Hi again

    something like that? 

    creat this new measure please: 

     

    New_Measure = 
    CALCULATE(
        sum(Order_rewards[reward_mediated_for_validator]),
        REMOVEFILTERS(Date_validated)
    )
    +
    CALCULATE(
        sum(Validated_per_day[reward]),
        REMOVEFILTERS(Date_mediated)
    )

     

    Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! ;-
    Best Regards
    BC

17 Replies

  • onurbmiguel_'s avatar
    onurbmiguel_
    Icon for Power Participant rankPower Participant

    Hello Dohaje

    Try to creat a new measure 

     

    new_measure = [measure_card A] + [measure_card B]

     

    Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! ;-
    Best Regards
    BC

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi, thanks, could you please advise, how to define the measure_card A? In the card A, it is just a column from a table. Thank you.

      • onurbmiguel_'s avatar
        onurbmiguel_
        Icon for Power Participant rankPower Participant

        hi again, 

        Is it a simple measure? Try: 

        1) # of A = sum(column A) 

        2) # of B = sum(column B) 

        3) # of total =sum(column A) + sum(column B) 

         

        Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! ;-
        Best Regards
        BC

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous,

    If these card visuals calculate based on different filter interactions, you can't direct calculate between them.
    For this scenario, you need to manually write calculate expressions to restore the filter effects of two calculations then you can get the different them.

    Regards,

    Xiaoxin Sheng

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi Xiaxin, 

      thank you. Could you please advise, how to manually write calculate expressions to restore the filter effects? I can google forward, but I dont know what for now :). Thank you.