Forum Discussion

Gschalk87's avatar
Gschalk87
Frequent Visitor
8 years ago
Solved

Help on measure formula

Hello All,   I am having some trouble figuring out how to make a measure work correctly, I am trying to get the count of final failures in a process.   i have data in a table that records part nu...
  • Seward12533's avatar
    Seward12533
    8 years ago

    Another approach that woudl work even If you don't have the date field suggested by jthomson.

     

    You could staging tables of serial numbers that have passed and failed using summarize with filters to capure only passing adn failing NS's respectively and include other calculated or relevant columns as needed,

     

    Passing SN = CALCULATETABLE(SUMMARIZE('StationEventHist',StationEventHist[PartSerialNbr]),'StationEventHist[EventID]<>65)

    Reject SN = CALCULATETABLE(SUMMARIZE('StationEventHist',StationEventHist[PartSerialNbr]),'StationEventHist[EventID]<>105)

     

    Then update you mesures to calculate form these tables and join the tables in your model by SN so any other filters you apply would work correctly.