Solved

decimel trncation after csv import

Posted on 2014-03-04
2
302 Views
Last Modified: 2014-03-04
There is a table Within the sql server  - the format of that  column in decimal(18, 0)
When I import the csv data into that sql server table and then compare the imported data to the original data – this is what I see –
The decimals are getting truncated resulting in 7000 less – how to fix this?

Original CSV Data      Imported Data in SQL Server
14010.1      14010
18283.56      18283
14745.5      14745
2102.211429      2102
2437.57      2437
2452.58      2452
2437.57      2437
2452.58      2452
2437.57      2437
2452.58      2452
2437.57      2437
2452.58      2452
2437.57      2437
2452.58      2452
2437.57      2437
2452.58      2452


thank you
0
Comment
Question by:Rayne
[X]
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
2 Comments
 
LVL 11

Accepted Solution

by:
Simone B earned 500 total points
ID: 39904867
The "0" in your data type DECIMAL(18,0) indicates that there are to be no decimals. You would need to change this in the table to the number of decimals you need. Eg DECIMAL(18,2)
0
 

Author Comment

by:Rayne
ID: 39904887
thank you Simone :)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

734 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