Forum Discussion

diogobraga2's avatar
diogobraga2
Helper IV
6 years ago
Solved

Calculate Straight or Weighted Average for the Total

The dataset has grade level data for schools (subset shown below). The goal is to calculate percentage of total for each grade AND for the whole school using this dataset.  Percent Enrolled = Total...
  • v-frfei-msft's avatar
    v-frfei-msft
    6 years ago

    Hi diogobraga2 ,

     

    As the error message, In your formual,  DISTINCTCOUNT should not be used like thay, please refer to my formula again.

    Measure 2 = 
    SUMX ( 'Table', [Measure] ) / DISTINCTCOUNT ( 'Table'[Grade] )

     

    Or you can share your pbix to me if you don't have any Confidential Information. Please upload your files to One Drive and share the link here.