Solved

DT_WSTR dropping value before decimal point in SSIS

Posted on 2010-08-25
2
707 Views
Last Modified: 2013-11-10
I'm trying to convert a value less than 1 e.g. 0.34 in to a string variable using DT_WSTR in a derived column transformation and it gets converted to ".34" rather than "0.34". How do I fix this please?
0
Comment
Question by:Grffster
  • 2
2 Comments
 
LVL 16

Accepted Solution

by:
vdr1620 earned 125 total points
ID: 33521780
Try converting it in your SQL Statement using Convert(Varchar(Length),ColumnName)..If your using any other Source..
 Try this ((ColumnName)< 1) ? "0"+ (DT_wstr,Length)(ColumnName) : (DT_wstr,Length)(ColumnName)


 
0
 
LVL 16

Expert Comment

by:vdr1620
ID: 33521790
use the above expression in your derived column by adding it as a new column and Map this column in your destination
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Question has a verified solution.

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

In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

914 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now