-//--------------------------------------------------------------------------------------------------
-
-function clear_gl_trans($type, $trans_id, $nested=false)
-{
- if (!$nested)
- begin_transaction();
-
- $sql = "DELETE FROM ".TB_PREF."gl_trans WHERE type=".db_escape($type)
- ." AND type_no=".db_escape($trans_id);
-
- db_query($sql, "could not clear gl transactions for type=$type and trans_no=$trans_id");
-
- if (!$nested)
- commit_transaction();
-}
-