Esempio n. 1
0
        public void delete(IList <QueryModel> qmList)
        {
            SqlConnection  cn = null;
            SqlTransaction tc = null;

            try
            {
                cn = DbHelperSQL.getConnection();
                tc = DbHelperSQL.startTransaction(cn);

                usersDal.del(cn, tc, qmList);

                DbHelperSQL.commitTransaction(tc);
            }
            catch (Exception dalEx)
            {
                DbHelperSQL.rollBackTransaction(tc);

                throw new MakeException(ExpSort.数据库, dalEx.Message);
            }
            finally
            {
                DbHelperSQL.closeConnection(cn);
            }
        }