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.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Error converting DataType to numeric

Author  Topic 

saiabhiram
Starting Member

17 Posts

Posted - 2010-04-18 : 23:10:41
Hello,

I am trying to put in a value 'RA342' INTO A FIELD in the database which is defined as decimal(6,0)

CAST('RA342' AS DECIMAL(6,0))

I get the error: Error converting varchar to numeric

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2010-04-18 : 23:14:04
what is your expected result ? How do you expect SQL Server to convert a string of "RA342" to decimal value ?


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page
   

- Advertisement -