List<keyValue> SQLStringList = new List<keyValue>();

foreach (KeyValuePair<string, decimal> item in datas)
{
SqlParameter[] parameters = {
new SqlParameter("@id", SqlDbType.VarChar,10),
new SqlParameter("@name", SqlDbType.Decimal)
};
parameters[0].Value = item.Key;
parameters[1].Value = item.Value;

string strsql = " update product set name=@namewhere id=@id";
SQLStringList.Add(new keyValue(strsql, parameters));
}

DbHelperSQL.ExecuteSqlTran(SQLStringList);
}

相关文章:

  • 2022-12-23
  • 2021-08-26
  • 2021-08-08
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-07-30
  • 2022-12-23
  • 2021-07-13
  • 2022-12-23
  • 2021-10-21
  • 2021-11-24
相关资源
相似解决方案