Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Bulk INSERT Query Problem

Author  Topic 

mukunda
Starting Member

4 Posts

Posted - 2008-01-22 : 01:03:55
Hi All

I am inserting the values by reading from the file using the bulk insert query. the problem is that file is in the local system its working fine. if the File in the network path how can i insert to the table can any one help me.

Thanks in advance
Mukund

CShaw
Yak Posting Veteran

65 Posts

Posted - 2008-01-22 : 02:36:59
Can you post your code for review?

Chris Shaw
www.SQLonCall.com
Go to Top of Page

ditch
Master Smack Fu Yak Hacker

1466 Posts

Posted - 2008-01-22 : 02:44:39
Firstly the user that sqlserver agent runs under needs to have access to the network path.
Secondly when specifying the file name use \\machinename\networkshare\filename.



Duane.
Go to Top of Page

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2008-01-22 : 04:54:20
BULK INSERT MyDB.MyTable.MyCol
FROM '\\computer\shared\data.txt';
GO


Jack Vamvas
--------------------
Search IT jobs from multiple sources- http://www.ITjobfeed.com
Go to Top of Page
   

- Advertisement -