Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
Pinto
Aged Yak Warrior
590 Posts |
Posted - 2007-03-14 : 11:48:18
|
I had an earlier problem updating a field in a sql table witha decimal which was sorted. I am now having the problem again.In the SQL table my field is type numeric and scale 2In my asp.net code I have stepped through the running code and the value is 77.50However when the sp updates the table it is stored as 78.In the sp the parameter is type numeric.TIA for any help |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-03-14 : 11:51:31
|
| What is the ASP.NET parameter datatype?Peter LarssonHelsingborg, Sweden |
 |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2007-03-14 : 11:52:21
|
Have you defined matching scale for parameter as well?Something like this:Create Proc something( @param1 numeric(20,2) ... Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
|
Pinto
Aged Yak Warrior
590 Posts |
Posted - 2007-03-14 : 11:55:33
|
| @param1 numeric(20,2)Has worked.Thank you once again Harsh Athalye for helping me.I have so much to learn - and remember |
 |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2007-03-14 : 12:00:55
|
| Glad it helped.Please note, however, numeric(20,2) is just an example. You will have to adjust precision and scale as per your needs.Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
|
|
|
|