Re: ODBC bcp
Richard Hughes <[email protected]>
| Newsgroups | gmane.comp.db.tds.freetds |
|---|---|
| Message-ID | <[email protected]> |
Here's my v3 patch (hopefully in a slightly more gitish format - still trying to figure out which of the various workflows on offer is appropriate). I think I've addressed everything discussed, including redoing how the new functions are called, adding some more stuff to the unit test and fixing a few bugs thereby found. I've got a couple of questions outstanding: 1) I think I've found a bug in Microsoft's sqlncli11: inserting from an application type of SQL_NUMERIC_STRUCT to a column of type varchar appears to ignore the 'scale' of the decimal. This is commented in the unit test, but causes an attempt to insert 3.141593 (SQL_NUMERIC_STRUCT) to come out as '3141593' (varchar). What's the general policy for things like this? Do we attempt bug-compatibility? I don't imagine many people will want this particular conversion - I only spotted it by accident. 2) I'm testing inserting to a datetime2 column. It works fine but tcpdump shows that it's actually being sent as a nvarchar over the wire, not binary. I'm assuming this is not my fault, but rather an underlying problem in src/tds/bulk.c which should be treated as a separate patch. If you think it is my fault then I'd appreciate it if you could point out where I might have gone wrong. Richard. _______________________________________________ FreeTDS mailing list [email protected] http://lists.ibiblio.org/mailman/listinfo/freetds
0001-Add-support-for-bcp-bulk-copy-using-ODBC-connections.patch.gz
(application/octet-stream, 12.9 KB) - not displayed