cannot convert between unicode and non-unicode

  • I have an SSIS package with a Data Flow Task which contains an OLE DB Source and an OLE DB Destination.

    The OLE DB Source is a SQL Command which contains a giant SELECT statement from a SQL Server 2005 database. The field referenced by the "cannot convert between unicode and non-unicode" error is a CHAR.

    The OLE DB Destination is a different SQL Server 2005 database. The corresponding field in the destination database is a VARCHAR. I get the same "cannot convert between unicode and non-unicode" error on this object, as well.

    Can someone shed some light on where unicode comes into play in a CHAR => VARCHAR conversion and how to resolve/prevent this? I read through some of the other forum posts regarding this error and none seemed to apply.

    Thanks in advance!!

  • Please disregard this question. With a little more digging, I found a nugget suggesting use of Advanced Editor. By going into Input and Output Properties, I was able to explicitly change the data type of the internal output column of the offending field. I don't know why the original package author had specified the output column as unicode!

  • Hi Mark,

    I am a super newbies and try the same import as you and I am getting the same error, can you be specific as to how you get to the advance option, I have look around and could not find it.

    Thank you

    Billy

  • Instead of double-clicking on the object to edit the basic properties, right-click on it and select Advanced Editor.

  • 😀 thank you Mark, you made my day.

  • hi dudes!

    i came across with the same error.

    The solution which i found was to create a package through import/export wizard ( it will create an extra data conversion DATA FLOW TRASNFORMATION) which will automatically convert between unicode and non unicode.

    Let me know if you need more explanation.:-)

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply