views:

92

answers:

1

I have created a very simple Data Flow in SSIS that is run inside a loop.

IMAGE 1

I have a simple OLE DB Source control which is connecting to a SQL Server and running quite a complex query to split daily data by 30 minute intervals as shown below.

IMAGE 2

I then have a Flat File Destination control which is taking the output from the OLE DB Source control and saving it as a comma-delimited CSV file. As you can see above the numbers are decimal numbers to two decimal places but in the CSV file below it is showing as ones and zeros.

IMAGE 3

What can I do to get the CSV output to match the query input? I have tried converting the numbers to varchar in the query but I got the same result. I also tried changing the column types in the Connection Manager too but got the same result.

A: 

I have managed to resolve this issue by changing all the DataType properties for each column of data I was importing. I had to change them to 'double-precision float [DT_R8]' and then it saved the CSV with the proper decimal values.

Very annoying, I hope that helps someone.

IMAGE 4

Ian Roke