{
$sql = "UPDATE ".TB_PREF."sales_order_details
SET qty_sent = qty_sent + $qty_dispatched";
if ($auto)
$sql .= ", quantity = quantity + $qty_dispatched";
$sql .= " WHERE id=".db_escape($line_id);
{
$sql = "UPDATE ".TB_PREF."sales_order_details
SET qty_sent = qty_sent + $qty_dispatched";
if ($auto)
$sql .= ", quantity = quantity + $qty_dispatched";
$sql .= " WHERE id=".db_escape($line_id);