0

I have problem in bulk insert, please anyone help me

Msg 4861, Level 16, State 1, Line 1
Cannot bulk load because the file "D:\BESTTA 7\20200518_DLLD_3C.txt" could not be opened. Operating system error code 3 (The system cannot find the path specified)

This is my SQL statement:

BULK INSERT LLD2017_26032020.dbo.TRX_TRANSAKSI_3C
FROM 'D:\\BESTTA 7\20200518_DLLD_3C.txt' --location with filename
WITH
(
    FIRSTROW = 2,
    FIELDTERMINATOR = '|',
    ROWTERMINATOR = '\n'
)
GO

SELECT *
FROM TRX_TRANSAKSI_3C ttt 
WHERE jenis_rekening = '3C' 
  AND ttt.TGL_TRANSAKSI = '20200518'
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
griyacode
  • 3
  • 1
  • 3

1 Answers1

0

It means, the SQL Server is not able to find the path. Are you having this file in the SQL Server machine ? If you are having this in your local server and running from SSMS client, SQL Server will not be checking this in your local machine.

'D:\BESTTA 7\20200518_DLLD_3C.txt' --location with filename

The above path SHOULD be present in the SQL Server server machine, local folder, NOT in your local machine, local folder

Venkataraman R
  • 12,181
  • 2
  • 31
  • 58