Tuesday, March 27, 2012

Error: Arithmetic overflow error converting numeric to data type numeric

Hello,
I'm using adonet to update the database hundreds of fields all at once and
got this exception/error:
"Arithmetic overflow error converting numeric to data type numeric", but it
doesn't tell me which specific column got overflown. Is there a way to find
out ? I have access to both the update code and the sql server.
Thank you very much in advance...Although I am not much of an ADO.Net person, I think that you get an errors
collection... SQL does return more info... Either it is in one of the other
messages or the one you are seeing is truncated... I did an arithmetic
overflow and got the following message..
Server: Msg 220, Level 16, State 2, Line 2
Arithmetic overflow error for data type tinyint, value = 3500.
--
Wayne Snyder, MCDBA, SQL Server MVP
Computer Education Services Corporation (CESC), Charlotte, NC
www.computeredservices.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Zeng" <zzy@.nonospam.com> wrote in message
news:%23Whl0SBJEHA.2440@.TK2MSFTNGP12.phx.gbl...
> Hello,
> I'm using adonet to update the database hundreds of fields all at once and
> got this exception/error:
> "Arithmetic overflow error converting numeric to data type numeric", but
it
> doesn't tell me which specific column got overflown. Is there a way to
find
> out ? I have access to both the update code and the sql server.
> Thank you very much in advance...
>|||hii
change the size of all your numeric fields in th data base to 38 and
precison to 0 and see..
ramesh|||If I don't error the error after that, how would I know which one?
"Ramesh" <ramesh@.mail.punecity.com> wrote in message
news:uJe8DkDKEHA.268@.TK2MSFTNGP11.phx.gbl...
> hii
> change the size of all your numeric fields in th data base to 38 and
> precison to 0 and see..
> ramesh
>sql

No comments:

Post a Comment