Need help with this Bulk Insert stored proc.
Posted on 2003-03-19
well I have following SP:
CREATE PROCEDURE [dbo]._blkIns_FlatFile
DECLARE @FullPath varchar
SET @FullPath = 'D:\inetpub\ftproot\' + @FileName
BULK INSERT m1.dbo.[User]
(CODEPAGE = 'ACP' , FIELDTERMINATOR ='\t' , ROWTERMINATOR ='\n' )
but allways reciving an erorr in line 7 (FROM @FullPath).
What I want is to upload file and give a name of file to stored proc
and then make an bulk insert. Question is what is wrong here, and is this possible
to create a dynamic name of the file to insert from.
Erorr messages is Bad syntax in near from @Fullpath in Line 7.
Hope someone has some idea.
Thanx a lot