Hello, I am looking to calculate the OTD on the Line orders for sales documents.
I would like to:
Actual Good Issue = NULL: If the expected good issue date => than TODAY then "Open - On Schedule" else "Open - late"
Actual Good Issue = DATE: IF the actual good issue date =< than EXPECTED GOOD ISSUE DATE then "On time" Else "Late"
Actual Good Issue Expected Good Issue Date Today Output
NULL 24.10.2017 24.10.2017 Open - On Schedule
NULL 22.10.2017 24.10.2017 Open - Late
23.10.2017 21.10.2017 24.10.2017 Late
25.08.2017 10.10.2017 24.10.2017 On time
thanks for your help
This should work:
If IsNull([Actual Good Issue]) AND [Expected Good Issue]>= Today() Then "Open - On Schedule"
ElseIF IsNull([Actual Good Issue]) AND [Expected Good Issue]< Today() Then "Open - Late"
ElseIf Not IsNull([Actual Good Issue]) and [Actual Good Issue]<= [Expected Good Issue] Then "On Time"