【问题标题】:BULK INSERT TASK gives following error when trying to load the data from txt file to databaseBULK INSERT TASK 尝试将数据从 txt 文件加载到数据库时出现以下错误
【发布时间】:2023-03-06 13:43:01
【问题描述】:
BULK INSERT [AG].[dbo].[tblSTAGINGTRANS]
from 'G:\Billing\Files\m2m.txt'
with (FIELDTERMINATOR='¦',ROWTERMINATOR='0x0a',CODEPAGE='ACP');

Msg 4832, Level 16, State 1, Line 1
Bulk load: An unexpected end of file was encountered in the data file.
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "BULK" for linked server "(null)" reported an error. The provider did not give any information about the error.
Msg 7330, Level 16, State 2, Line 1
Cannot fetch a row from OLE DB provider "BULK" for linked server "(null)"

我收到以下错误。该文件来自大型机。我猜是Linux系统。我尝试使用 \r\n, \n 但没有运气。

谁能帮帮我?

【问题讨论】:

    标签: sql sql-server tsql sql-server-2012 ssis-2012


    【解决方案1】:

    你没有丢失驱动器号后面的第一个 \ 吗?

    BULK INSERT [AG].[dbo].[tblSTAGINGTRANS]
    from 'G:\Billing\Files\m2m.txt'
    with (FIELDTERMINATOR='¦',ROWTERMINATOR='0x0a',CODEPAGE='ACP');
    

    【讨论】:

    • 是那个问题还是它仍然给出那个错误?
    猜你喜欢
    • 1970-01-01
    • 2013-01-23
    • 2017-08-05
    • 2021-06-13
    • 2018-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多