Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

measure calculation help

I have a table  Table1 with below columns 

col1,  col2,   col3,   startdate,    targetdate

 

I want to create a measure something like below. Can you help me with correct syntax.

CALCUATE(
            DISTINCTCOUNT(col1),
   filter(      startdate  > Targetdate,

         col2 = "abc",
         col3 = "xyz")

 

  •  

    Measure = 
    CALCULATE(
        DISTINCTCOUNT(SampleData[col1]),
        FILTER(SampleData, SampleData[startdate] > SampleData[targetdate] && SampleData[col2]="abc" && SampleData[col3] = "xyz")
    )

     

     

1 Reply

  • bolfri's avatar
    bolfri
    Solution Sage

     

    Measure = 
    CALCULATE(
        DISTINCTCOUNT(SampleData[col1]),
        FILTER(SampleData, SampleData[startdate] > SampleData[targetdate] && SampleData[col2]="abc" && SampleData[col3] = "xyz")
    )