[quoted text, click to view] On May 29, 6:53 pm, "Hari Prasad" <hari_prasa...@hotmail.com> wrote:
> Hello,
>
> Does the SQL Server service startup account have read access in C drive root
> in SQL Server machine?
>
> Thanks
> Hari
>
> "Hulicat" <dennis_A_wh...@yahoo.com> wrote in message
>
> news:1180489060.372492.177180@z28g2000prd.googlegroups.com...
>
> >I am trying to do a bulk insert
> > here is the error:
> > Server: Msg 4860, Level 16, State 1, Line 1
> > Could not bulk insert. File 'c:\what.fmt' does not exist.
>
> > Here is what I am executing:
>
> > BULK INSERT callinsecuritycodeprovider
> > FROM 'C:\sample.txt'
> > WITH
> > (
>
> > FIRSTROW = 2
> > , FIELDTERMINATOR = ','
> > , FORMATFILE = 'c:\what.fmt'
>
> > , ROWTERMINATOR = '\n'
>
> > )
>
> > GO
>
> > both files reside on the root of the sql box and my user has full
> > access. I read some where people had the same error, however' my
> > problem seems to be different as the solutions did not work..
>
> > Any help would be greatly appreciated.
Thanks that was @ least solved the initial error after I moved the
format file to a shared location:
However, it's throwing an error on the format file itself.
Server: Msg 4823, Level 16, State 1, Line 1
Could not bulk insert. Invalid column number in format file
Here is the format file
8.0
1 bigint "" 1 ID SQL_Latin1_General_Cp437_BIN
2 char 7 "" 2 SecurityNumber
SQL_Latin1_General_Cp437_BIN
3 bit "\n" 3 IsAssigned SQL_Latin1_General_Cp437_BIN
I have only three columns ID, SecurityNumber and IsAssiged in the
table
What am I missing?
Thanks!