Forum Discussion

Amrselim1989's avatar
Amrselim1989
Helper II
2 years ago
Solved

Optimizing sumx

hello, kinldy i have very simple sumx calculation    it iterates agients 3 million row in a table and about 300 rows in another table; the code is    Sum of Net Sales Value in USD = sumx('Tabl...
  • mickey64's avatar
    2 years ago

    For your reference.

    I use ’SUM’ instead of 'SUMX'.

     

    Step 1: I make a calendar table and add 2 relationships.

    Step 2: I make a measure below.

        Measure = DIVIDE(SUM('Table'[Net Sales Value]),AVERAGE('RateDate'[USD Price]))

     

    Step 3: I make a matrix below.