DELETE FROM tHE_OrderSurrCh WHERE acKey = @acKey; 
DELETE FROM tHE_OrderDispList WHERE acKey = @acKey; 
DELETE FROM tHE_OrderItem WHERE acKey = @acKey; 
DELETE FROM tHE_OrderPrSt WHERE acKey = @acKey; 
DELETE SR FROM tHE_StockRes SR 
    JOIN tHE_StockResOrder SRO ON SR.anQId = SRO.anStockResQId 
    JOIN the_OrderItem OI ON OI.anQId = SRO.anOrderItemQId 
WHERE OI.acKey = @acKey; 
DELETE FROM tHE_MoveItemSerialNo WHERE acKey = @acKey; 
DELETE FROM tHE_MoveInstPay WHERE acKey = @acKey; 
DELETE FROM tPA_Link WHERE acKey = @acKey; 
DELETE FROM tPA_Link WHERE acLnkKey = @acKey; 
DELETE FROM tHE_LinkOrderOrder WHERE acKey = @acKey; 
DELETE FROM tHE_LinkOrderItemProdSt WHERE acKey = @acKey;