Forum Discussion

545's avatar
545
Frequent Visitor
2 years ago
Solved

Count Measure with Filter

i have this measure:

# Total_Eng_reports_By_date =
VAR x = CALCULATE(DISTINCTCOUNT(qryAssemblyProcessReport[ItemID]), tblStations[StationCode]=28)
return IF(ISBLANK(x), 0,x)
 
the date is set to 4/3/2024 
 
it checks if the item is in station 28, and if it is so then it counts it as 1.
 
 it counted 5.

 

but there are 16 in power query 

 

 

AssemblyDocNo             ItemID                   itemclass        OrderID                stationcode           employeecode       process date   

 

3 Replies

  • _AAndrade's avatar
    _AAndrade
    Resident Rockstar

    Hi 545,

    Can you provide a sample pbix file with same data so I can take a look?

     

    • 545's avatar
      545
      Frequent Visitor

      is there a quick way to do that?