Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


SSIS SQL 2012 OLEDB Source defaults all Date columns to DT_WSTR


SSIS SQL 2012 OLEDB Source defaults all Date columns to DT_WSTR

Author
Message
Daniel Forrester 123
Daniel Forrester 123
SSC Veteran
SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)

Group: General Forum Members
Points: 266 Visits: 195
Hi,

I have a data flow task that moves date from one SQL 2012 Database to another SQL 2012 database using an OLEDB source. I have a problem that all columns of type Date are being mapped to the DT_WSTR datatype in SSIS.

I have found the following which is quite interesting. I have checked the default mapping in the MSSQLToSSIS10.xml file and the Date datatype is mapped to DT_DBDATE as I would expect.

http://www.simple-talk.com/sql/ssis/working-with-ssis-data-types/

Has anybody else encountered this or have any ideas?

Regards
Daniel
Koen Verbeeck
Koen Verbeeck
SSCoach
SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)

Group: General Forum Members
Points: 16538 Visits: 13210
What if you change the datatype of the output column in the advanced editor? Does that work?



How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at SQLKover.

MCSA SQL Server 2012 - MCSE Business Intelligence
Daniel Forrester 123
Daniel Forrester 123
SSC Veteran
SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)SSC Veteran (266 reputation)

Group: General Forum Members
Points: 266 Visits: 195
Hi,

Using the advanced editor does work but I have quite few packages with this problem.

I'm pretty sure the problem is related to the MSSQLToSSIS10.XML mapping file but nothing I seem to do affects the way SSIS maps the columns. I think I am missing something here.

However I have found that changing the OLEDB provider for my source connections from 'Microsoft OLE DB Provider for SQL Server' to 'SQL Server Native Client 11.0' fixes the problems as SSIS maps the columns to the right data types.

The problem is not fixed but the work arround isn't too bad.

Thanks
Daniel
Koen Verbeeck
Koen Verbeeck
SSCoach
SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)

Group: General Forum Members
Points: 16538 Visits: 13210
Daniel Forrester 123 (12/13/2012)
Hi,

Using the advanced editor does work but I have quite few packages with this problem.

I'm pretty sure the problem is related to the MSSQLToSSIS10.XML mapping file but nothing I seem to do affects the way SSIS maps the columns. I think I am missing something here.

However I have found that changing the OLEDB provider for my source connections from 'Microsoft OLE DB Provider for SQL Server' to 'SQL Server Native Client 11.0' fixes the problems as SSIS maps the columns to the right data types.

The problem is not fixed but the work arround isn't too bad.

Thanks
Daniel


Ah yes, it is recommended to use the native client instead of the MS OLE DB provider for SQL Server. This is one of those reasons Smile



How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at SQLKover.

MCSA SQL Server 2012 - MCSE Business Intelligence
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search