Update Beastmode for % Right First Time (to remove exceptions)

Hi,

Trying to work out % right first time (RFT) and am almost there. BUT, when using the calculation below, it counts all "discrepancies" as RFT (100%) where it is only those associated with the 'not in' discrepancy records which are 100% and those which don't fall into the numbers listed as 0%.

Please could you help with updating the beastmode to suit this purpose or recommend how to acheive this?

Thanks!


1-

count(distinct case

 when `HOLD_NAME` in ('Incomplete Info' ,'PO – INVOICE HOLD', 'PENDING PO OVERRIDE' , 'CREDIT HOLD- INVOICE HOLD','CCCL Info Incomplete')

  then `Study Number`

 when `HOLD_NAME` not in ('Discrepancy 121901','Discrepancy 121275', 'Discrepancy 121325','Discrepancy 121566','Discrepancy 121802', 'Discrepancy 122848', 'Discrepancy 118253','Discrepancy 118549','Discrepancy 119478','Discrepancy 120171','Discrepancy 119688','Discrepancy 120585','Discrepancy 120701', 'Discrepancy 121653', 'Discrepancy 121654', 'Discrepancy 117366','Discrepancy 118859','Discrepancy 118328','Discrepancy 119043','Discrepancy 119765','Discrepancy 118983','Discrepancy 121084','Discrepancy 121213','Discrepancy 121214','Discrepancy 120360','Discrepancy 122094','Discrepancy 122808','Discrepancy 122835','Discrepancy 122508')

  and `HOLD_NAME` like '%Discrepancy%'   

  and `RETURNCODE` is not null  

  then `Study Number` 

end) / count(distinct `Study Number`)

Answers

  • Hi @Katie_Forrest_2022 ,

    Trying to understand your above message so I may need some more context or examples to see to help. So what is the result you are seeing? You're getting 100%? If you were to break this out, what do you get for a numerator and what do you get for a denominator separately?

    John Le

    You're only one dashboard away. 

    More video solutions at: https://www.dashboarddudes.com/pantry

  • @Katie_Forrest_2022

    checking your code , would it be that you forgot to say...

    and `HOLD_NAME` NOT LIKE '%Discrepancy%' 
    
    instead of 
    
    and `HOLD_NAME` like '%Discrepancy%' 
    
    
    
    Domo Arigato!

    **Say 'Thanks' by clicking the thumbs up in the post that helped you.
    **Please mark the post that solves your problem as 'Accepted Solution'
  • @DashboardDude

    Hi,

    Thanks for your message. There are lots of different "HOLD_NAME" types and for some they are right first time and for others they are not. I've tried to give an example below of what I'm currently getting and what it needs to be. At the moment, because of the hold name "not in" for discrepancies ###, it counts all discrepancies as right first time.

    I've attached a mock excel spreadsheet for additional info . Of the 25 studies listed, 14/25 are currently RFT (~56%) but this should only be 8/25 RFT (~32%). Hope this helps :-) and thanks for your input!!!