(ITS#5607) Double close problem for SQL handles in back-sql