存储过程中的声明@test decimal(18,3) output
   select @test=test from mytest where id=1程序中得到输出参数的方法为
SqlCommand cmd=new SqlCommand();
.........
cmd.Parameters.Add("@test",SqlDbType.Decimal);
cmd.Parameters["@test"].Direction=ParameterDirection.Output;...........
cmd.ExecuteNonQuery();
数据库中test 的值本来为3002.123
可是在返回值中得到的却是3002,小数没了
这是为什么呀,求救!!! 我在cmd添加参数类型SqlDbType.Decimal时怎么能指定小数位数呢,我想可能就是这里错了,可是怎么改呀。以前我记得参数可以是double型,可是现在我在输了sqldbtype.后怎么没有double可选呢.