Beispiel #1
0
 /// <summary>
 /// 执行数据更新的sql语句[带输入参数]
 /// </summary>
 /// <param name="sql"></param>
 /// <param name="parms"></param>
 /// <returns></returns>
 public static bool Sql(this StringBuilder sql, ParCollection prams = null)
 {
     using (DBDalOperate dal = new DBDalOperate())
     {
         return(dal.ExecSqlNoQuery(sql, prams) > 0 ? true : false);
     }
 }
Beispiel #2
0
 /// <summary>
 /// 执行数据更新的sql语句[带输入参数]
 /// </summary>
 /// <param name="sql"></param>
 /// <param name="parms"></param>
 /// <returns></returns>
 public static bool Sql(this AutoPar auto)
 {
     using (DBDalOperate dal = new DBDalOperate())
     {
         auto.End();
         return(dal.ExecSqlNoQuery(auto.strSql, auto.pars) > 0 ? true : false);
     }
 }