Forum Discussion

Jos13's avatar
Jos13
Helper III
5 years ago
Solved

Sum Distinct Values

Hi Team,   I have the following data. I want to create a measure that calculates Customer A's sale as 100 when user selects Jan 1 on slicer and 220 if user selects date range between 1st and...
  • nandukrishnavs's avatar
    5 years ago

    Jos13 

     

    Try the below DAX measure.

     

    Measure1 =
    VAR _x =
        SUMMARIZE ( 'Table', 'Table'[Date], 'Table'[Customer], 'Table'[Sale] )
    VAR _sum =
        SUMX ( _x, [Sale] )
    RETURN
        _sum

     

     

     




    Regards,
    Nandu Krishna

    Did I answer your question? Mark my post as a solution!
    Appreciate with a kudos 👍

    Proud to be a Super User!