Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Runtime Err. Arithmetic Overflow Error Converting Numeric to DataType Numeric

Posted on 2004-04-09
8
671 Views
Last Modified: 2013-12-25
Hi,
I'm Trying to update my database with a numeric valule of a particular table.  While doing this process I'm getting the runtime error (-2147217833) Arithmetic Overflow error converting Numeric to Datetype Numeric.

The DataBase I'm using is SqlServer. I'm begining a session within that session I'm updating a same table twice, the first time it is getting updated but it fails in the 2nd time.

Can you pls. help me in this regard

Regards
0
Comment
Question by:spk2shankar
8 Comments
 
LVL 6

Expert Comment

by:mmusante
ID: 10791054
It seems like your update is between to different number formats and that in some case the conversion is not possible

(for example converting a Int to a SmallInt)

plese post your update query and the table definition ...
0
 

Author Comment

by:spk2shankar
ID: 10791206
Hi  mmusante
thank you for showing interest

My table structure is like this
Table Name - > Remit

Columns
   Remit_No       Numeric(7),
   Remit_Date    SmaleDateTime,
   Remit_Curr    Varchar(3),
   Remit_amt     Numeric(18,3),
   Remit_Batch   Numeric(7)

First I'm updating the table with amount at that point of time it is getting updated. Then
I'm updating the table with a query Update Remit set Remit_Batch = 17 where Remit_No = 76584
and Remit_Date = '2004-04-09'

Regards
0
 
LVL 6

Expert Comment

by:mmusante
ID: 10791341
Try changing the date condition to ...
Remit_Date = {d '2004-04-09'}
0
Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

 

Author Comment

by:spk2shankar
ID: 10792289
hi mmusante
thankyou I even tried that, that is not working
regards
0
 
LVL 27

Expert Comment

by:Dabas
ID: 10793440
Hi spk2shankar:
> and Remit_Date = '2004-04-09'
This definitely is wrong.
Have you tried
and Remit_Date = CONVERT(DATETIME, '2004-04-09 00:00:00', 102))

Dabas
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 90 total points
ID: 10803399
There does not appear to be anything illegal about this statement:
Update Remit
set Remit_Batch = 17
where Remit_No = 76584 and Remit_Date = '2004-04-09'

So I would suggest you check to see where exactly you are getting the error and if possible attempt to duplicate it in SQL Query Analyzer.

Also, are you going to return to the following open question?
http://www.experts-exchange.com/Databases/Microsoft_SQL_Server/Q_20927090.html
0
 
LVL 29

Expert Comment

by:leonstryker
ID: 11315797
No comment has been added to this question in more than 21 days, so it is now classified as abandoned..
I will leave the following recommendation for this question in the Cleanup topic area:

Answered acperkins

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

leonstryker
EE Cleanup Volunteer
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
change vba from autofit to 13.5 width? 4 29
VBA saving file message display 5 72
IF ELSE Statement in Excel Macro VBA 16 75
Formula problem with Excel attachment 6 38
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question