473,386 Members | 1,823 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

convert nvarchar(number with thousandsseparator) to integer

Guys, I've been trying to convert/cast a nvarchar value like
719.928,000000 to a number but I keep getting a conversion failed error.

I think it's the thousandsseparator that's giving me troubles but I have no idea how to tell sql that the string is a number formated a special way like I can do with date styles.

Can anyone help me? Do I need to remove the thousandsseparator before the convert/cast? And if so, how should I do that?

Thanx

PS. just to be clear, integer in the topic should be number/decimal (19,6)
Dec 7 '10 #1
1 2863
ck9663
2,878 Expert 2GB
Try removing the comma using the REPLACE() function before you cast it into number.

Good Luck!!!

~~ CK
Dec 7 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: lizayica | last post by:
How to convert a string like '2,3,4' to three integer 2,3,4 in SQL procedure of DB2 UDB 8.2? Thanks!
7
by: whatluo | last post by:
Hi, all I'm now working on a program which will convert dec number to hex and oct and bin respectively, I've checked the clc but with no luck, so can anybody give me a hit how to make this done...
2
by: Ricardo Quesada | last post by:
Hi, In python 2.0, this number was an integer: 0x88776655 but in python 2.4 it is a long (every number > 0x7fffffff it is a long) in python 2.4, is there a way to convert that number to a...
3
by: priyanka | last post by:
Hi there, I want to convert a String into integer. I get the string from a file using : string argNum; getline(inputStream,argNum); I now need to convert argNum into integer.
7
by: shellon | last post by:
Hi all: I want to convert the float number to sortable integer, like the function float2rawInt() in java, but I don't know the internal expression of float, appreciate your help!
15
by: Lyosha | last post by:
Converting binary to base 10 is easy: 255 Converting base 10 number to hex or octal is easy: '0144' '0x64' Is there an *easy* way to convert a number to binary?
1
by: getnitha | last post by:
how to convert a number to time format in vb.net eg: 8 to 8:00:00 i am storing in sql server number as nvarchar while retreiving in code i need to convert it as 8:00:00 for further calculations...
10
by: iaslam | last post by:
How can we convert a character into integer char a my input to this may be like 21466845687552 now i want to access each element and want to convert it into integer and then apply aritmatic...
10
by: FAQ server | last post by:
----------------------------------------------------------------------- FAQ Topic - How do I convert a Number into a String with exactly 2 decimal places?...
4
subedimite
by: subedimite | last post by:
Here I am with another question being a very new VBA user. I have this scenario to work with: I would think this is fairly common routine of work for VBA. I have a string of hex contents as...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.