没看懂你说的意思
我一般用着两种方法
string sql = "update ClassType set className='"+className+"' where classId="+classId;
string sql = "insert into TuiGuang(tgName,tgUrl,orderNum)values(@tgName,@tgUrl,@orderNum)";
OleDbParameter[] parms = new OleDbParameter[]{
new OleDbParameter("@tgName",tg.TgName),
new OleDbParameter("@tgUrl",tg.TgUrl),
new OleDbParameter("@orderNum",tg.OrderNum),
};
int num = DBHelper.ExecuteCommand(sql, parms);