|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Bulk Insert empty filestext file into a table. The code is like this: BULK INSERT FT_MASK FROM 'e:\interfa\input\Cot\ftp\mdir.txt' WITH (CODEPAGE='ACP') The problem that I found is when mdir.txt is empty (0 bytes). Randomly triggers the following error: Bulk Insert fails. Column is too long in the data file for row 1, column 1. Make sure the field terminator and row terminator are specified correctly. Server: Msg 7399, Level 16, State 1, Line 1 OLE DB provider 'STREAM' reported an error. The provider did not give any information about the error. Bulk Insert: DataFileType was incorrectly specified as char. DataFileType will be assumed to be widechar because the data file has a Unicode signature. OLE DB error trace [OLE/DB Provider 'STREAM' IRowset::GetNextRows returned 0x80004005: The provider did not give any information about the error.]. The statement has been terminated. I said randomly, because trying even with the same file sometimes there is no error and sometimes yes. mdir.txt is generated by the ftp sentence "mdir" |
|||||||||||||||||||||||