Neither humans nor computes can divide by zero, so if your SQL script has a variable in the denominator of an equation, be sure to safe-guard against a potential divide-by-zero error:
CASE
WHEN @AveWorkDays = 0 THEN 0
ELSE
ISNULL(SUM(CAST(ItemInventory.QtyDistributed As decimal))/@AveWorkDays, 0)
END