473,327 Members | 1,967 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,327 software developers and data experts.

Data Type Help How do I convert SQL Numeric/Decimal to SQL BigInt?

21
I am reading in a SQL data type of Numeric and trying to write it out to another SQL table where the field is defined as BigInt. I am presetly putting the data into a Dim indata as String. I can see the data there but I get an error when I try to put it into the SQL field of BigInt. Is there a conversion function or what data type to I need to store it in within my VB program?
Jan 10 '07 #1
2 2932
willakawill
1,646 1GB
I am reading in a SQL data type of Numeric and trying to write it out to another SQL table where the field is defined as BigInt. I am presetly putting the data into a Dim indata as String. I can see the data there but I get an error when I try to put it into the SQL field of BigInt. Is there a conversion function or what data type to I need to store it in within my VB program?
Hi try CLng(indata)
Jan 10 '07 #2
Killer42
8,435 Expert 8TB
I am reading in a SQL data type of Numeric and trying to write it out to another SQL table where the field is defined as BigInt. I am presetly putting the data into a Dim indata as String. I can see the data there but I get an error when I try to put it into the SQL field of BigInt. Is there a conversion function or what data type to I need to store it in within my VB program?
If the CLng doesn't work, then please tell us what error you are getting. Perhaps the number is too large, or BigInt doesn't like decimal points.
Jan 11 '07 #3

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

Similar topics

21
by: Batista, Facundo | last post by:
Here I send it. Suggestions and all kinds of recomendations are more than welcomed. If it all goes ok, it'll be a PEP when I finish writing/modifying the code. Thank you. .. Facundo
1
by: piero | last post by:
Hi, I have a Excel sheet that have a column with mixed data: column can contain data like "892-234-32A" or like "892298343233432" I need to get all data column such as "text" to avoid numeric...
5
by: David Garamond | last post by:
In Interbase and Firebird, NUMERIC is implemented as 64-bit integer. This limits the range to NUMERIC(18, *) but for many uses that's adequate. And moreover it's fast and efficient. Is there a...
3
by: Oliver Stratmann | last post by:
Hello All! I'm looking for a description of the needs of space for a certain data-type. How much space does e.g. a NUMERIC(1,0)- field take? (??? Bytes?) Is there a listing in the...
2
by: Marc Heravi | last post by:
Hello NG, for overflow reasons on numerical accumulation of an int column during SELECTion i have to change the data type of a column from "int" to "bigint". However that doesn't apply to the...
4
by: Ken Varn | last post by:
I have an unknown numeric Type object passed into a function. I want to run a conversion on a string to convert the string to that Type object and return an object of that type. Is there some way...
6
by: M.A. Oude Kotte | last post by:
Hi All, I hope this is the correct mailing list for this question. But neither postgresql.org nor google could help me out on this subject. I did find one disturbing topic on the mailing list...
5
by: Pavils Jurjans | last post by:
Hello, I am somewhat lost in the implicit/expicit possible/impossible type casting in C#... I need to write a class, which among other things, must have wat to read a numeric value type, and...
8
MMcCarthy
by: MMcCarthy | last post by:
Type MemSize RetVal of VarType() Declaration Char Conversion Boolean 2b vbBoolean(11) CBool() Byte 1b vbByte(17) ...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.