C#调用存储过程SqlParameter()问题

 当使用SqlParameter进行数据赋值时,如果数据类型是float类型,数据传递执行时值等于10.9添加到数据库就会变成10.89,解决此问题需要将数据类似float转换成decimal 

如:new SqlParameter("@price",Entry.Price)  Entry.Price属性数据类型定义为decimal 

原文地址:https://www.cnblogs.com/leojon/p/5795663.html