Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
kenji_khoo
Partner - Contributor
Partner - Contributor

On Time and In Full in expression

I'm developing an On Time and In Full calculation, OTIF Dashboard. Previously i used backend script to develop the calculation but my customer would like to have some kind of what-if analysis therefore i have to do the calculation "on the fly" in frontend expression.

Scenario at below:

OTIF by Sales Order Line: When fulfilled On time + In full, then OTIF is fulfilled. 

Sales OrderSales Order LineOn TimeIn FullOTIF
 Formula=count({<SO_Key={"=OTIF_Date >= Cust_GI_Date"}>}SO_Key)

count({<SO_Key={"=sum(Deliver_Net_Weight_KG)>=MinOrderQuanity 
and  sum(Deliver_Net_Weight_KG)<=MaxOrderQuantity"}>}
SO_Key)

count({<SO_Key={"=sum(Deliver_Net_Weight_KG)>=MinOrderQuanity 
and  sum(Deliver_Net_Weight_KG)<=MaxOrderQuantity"}>*< SO_Key={"=OTIF_Date >= Cust_GI_Date"}>}
SO_Key)
 Total343
2001232210111
2001232220111
2001232230111
2001232240010

 

The above calculation i have no issue but when come to calculate by Sales Order Line.

How to calculate Sales Order? Is when any of the Sales Order Line's OTIF is 0, the entire Sales Order's OTIF will be 0. How to get the below result using frontend expression? I know this message might trouble but I seeking your advice. Thanks

Sales OrderOn TimeIn FullOTIF
FormulaThe on time is zero because one of the Sales order line is zeroThe in full is 1 because all the Sales Order Line is met.Hence, 0.
Total010
20012322010

 

1 Solution

Accepted Solutions
Kushal_Chawda

can you try below. If not working then would you be able to provide sample?

Count(total <[Sales order line]>{<SO_Key={"=sum(Deliver_Net_Weight_KG)>=MinOrderQuanity 
and  sum(Deliver_Net_Weight_KG)<=MaxOrderQuantity"}>*< SO_Key={"=OTIF_Date >= Cust_GI_Date"}>}
SO_Key)

View solution in original post

1 Reply
Kushal_Chawda

can you try below. If not working then would you be able to provide sample?

Count(total <[Sales order line]>{<SO_Key={"=sum(Deliver_Net_Weight_KG)>=MinOrderQuanity 
and  sum(Deliver_Net_Weight_KG)<=MaxOrderQuantity"}>*< SO_Key={"=OTIF_Date >= Cust_GI_Date"}>}
SO_Key)