Calling convention: SCM_Calc_Order_LeadTime("Buchungsperiode": String, ProductID: Integer, DataID: Integer, "Geschaeftsart": String): Float
Description: Calculates average order lead time for a product and its business subset, then writes both values to the specified current-object record.
Parameters:
Buchungsperiode: booking period used to filter orders.
ProductID: product identifier.
DataID: current-object record to update.
Geschaeftsart: business type used for the subset calculation.
Returns: Product average order lead time when positive; otherwise NULL. The function also updates product and subset fields.
Availability: Default; SCM-specific and dependent on the current object's virtual SQL and the orders schema.
Example:
LeadTime := SCM_Calc_Order_LeadTime("2026-08", ProductID, DataID, "Retail");