Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 unicode to non-unicode problem

Author  Topic 

Trudye
Posting Yak Master

169 Posts

Posted - 2008-07-16 : 07:10:16
Hey Guys, got a question. I recieved an error:
.....cannot convert between unicode and non-unicode data type strings.
I went to the knowledge base and discovered that I needed to change my input format (in SSIS) to 'Unicode string [DT_WSTR]' format. But what am I suppose to do with my Numeric fields? I tried using 'Unicode text stream [DT_NTEXT]' but that didn't go over well either.

Any ideas on what will work? Also this same file has to be exported again. I do a quick update to 1 or 2 fields and out it goes. So the numeric fields must be numeric when the user gets them.

Thanks much,
Trudye


visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-07-16 : 07:15:21
use DT_R4 or DT_R8

http://msdn.microsoft.com/en-us/library/ms141036.aspx
Go to Top of Page

Trudye
Posting Yak Master

169 Posts

Posted - 2008-07-16 : 08:47:03
Hi visakh16, thanks so much for responding. I tried DT-R8 and received msg:
Do you want to replace the metadata of the output cols with the metadata of the external cols?

I replied 'yes'. He complained about the DT_R8 so I changed it to DT_WSTR, which he took. My guess is they are sending me text fields back instead of the numeric fields I am sending them. Anywho well, see when I return this file to them next week.

Thanks for all you help, it may not seem like it but I did learn something. Hopefully I'll get the hang of this SSIS very soon.

Be well,
Trudye
Go to Top of Page
   

- Advertisement -