![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I am importing data from a csv file into a SQLSERVER table I am having problems with a field in the destination table which is of type binary. The source data in the csv file is a Hex representation of the binary data. e.g. 0x000386006bc886a0 An exception is being raised - General conversion failure pair 1(source column 'Col001'(DBTYPE_STR), destination column 'Id' (DBTYPEWS_BYTES) I have read in the help that if the destination column is binary no translation occurs. Is there ay way to get around this thanks Andrew |
#3
| |||
| |||
|
|
In message <A000EC31-437B-4688-81A1-AFED7EA9FFE0 (AT) microsoft (DOT) com>, Andrew Andrew (AT) discussions (DOT) microsoft.com> writes I am importing data from a csv file into a SQLSERVER table I am having problems with a field in the destination table which is of type binary. The source data in the csv file is a Hex representation of the binary data. e.g. 0x000386006bc886a0 An exception is being raised - General conversion failure pair 1(source column 'Col001'(DBTYPE_STR), destination column 'Id' (DBTYPEWS_BYTES) I have read in the help that if the destination column is binary no translation occurs. Is there ay way to get around this thanks Andrew I'd guess that the conflict is around a string to byte conversion. So you should either store the hex representation in a string/text field, or convert it back to byte data as part of the transform. Depending what type of data this is and if you have control over both ends of the process, you may find the Read and Write file transformations of use, and skip the whole encoding nightmare. -- Darren Green (SQL Server MVP) DTS - http://www.sqldts.com PASS - the definitive, global community for SQL Server professionals http://www.sqlpass.org |
#4
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |