Home All Groups Group Topic Archive Search About


Author
15 Mar 2006 4:49 AM
doller
Dear all,

I created a BCP file from SQL Server2000 with .BCP Extension.
Now i am trying to load data in the SQL Server2005 Database table.
First was getting the error of remote connection which i solved .
Now i am getting this below error

SQLState = HY000, NativeError = 0
Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
NULL

I am executing this code
exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'

Pls help

from
Doller

Author
15 Mar 2006 8:20 AM
Cube
hi

there is an error in your syntex, it's complaining about your error file
u have -n -"EPI-IT-SUFIAN\SQL_DATA"
is this the location for your error / log ilfe  -"EPI-IT-SUFIAN\SQL_DATA"
if so then you have to add the -e switch and add a file name as well

and u are specifying login and password with blank values ??
-U -P



Show quoteHide quote
"doller" wrote:

> Dear all,
>
> I created a BCP file from SQL Server2000 with .BCP Extension.
> Now i am trying to load data in the SQL Server2005 Database table.
> First was getting the error of remote connection which i solved .
> Now i am getting this below error
>
> SQLState = HY000, NativeError = 0
> Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> NULL
>
> I am executing this code
> exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
>
>  Pls help
>
> from
> Doller
>
>
Are all your drivers up to date? click for free checkup

Author
15 Mar 2006 8:30 AM
John Bell
Hi

Assuming epinav.dbo.Sp_who_Perocess  is a table or view, you should get the
command working from a command prompt and then fit that into the xp_cmdshell
call.

Try the following adding the correct loginid and password:

exec master..xp_cmdshell ' BCP  "epinav.dbo.Sp_who_Perocess" in
"c:\Sp_who_Perocess.bcp" -n -S "EPI-IT-SUFIAN\SQL_DATA" -U {loginid} -P
{password}'

John


Show quoteHide quote
"doller" wrote:

> Dear all,
>
> I created a BCP file from SQL Server2000 with .BCP Extension.
> Now i am trying to load data in the SQL Server2005 Database table.
> First was getting the error of remote connection which i solved .
> Now i am getting this below error
>
> SQLState = HY000, NativeError = 0
> Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> NULL
>
> I am executing this code
> exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
>
>  Pls help
>
> from
> Doller
>
>
Author
15 Mar 2006 9:12 AM
John Bell
Hi

This assumed that EPI-IT-SUFIAN\SQL_DATA was the database server if not
please let us know what it is supposed to be!

You can check the format and parameters of the BCP utility in books online.

John

Show quoteHide quote
"John Bell" wrote:

> Hi
>
> Assuming epinav.dbo.Sp_who_Perocess  is a table or view, you should get the
> command working from a command prompt and then fit that into the xp_cmdshell
> call.
>
> Try the following adding the correct loginid and password:
>
> exec master..xp_cmdshell ' BCP  "epinav.dbo.Sp_who_Perocess" in
> "c:\Sp_who_Perocess.bcp" -n -S "EPI-IT-SUFIAN\SQL_DATA" -U {loginid} -P
> {password}'
>
> John
>
>
> "doller" wrote:
>
> > Dear all,
> >
> > I created a BCP file from SQL Server2000 with .BCP Extension.
> > Now i am trying to load data in the SQL Server2005 Database table.
> > First was getting the error of remote connection which i solved .
> > Now i am getting this below error
> >
> > SQLState = HY000, NativeError = 0
> > Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> > NULL
> >
> > I am executing this code
> > exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> > epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
> >
> >  Pls help
> >
> > from
> > Doller
> >
> >
Author
15 Mar 2006 10:04 AM
doller
Hi all,

EPI-IT-SUFIAN is my server name and SQL_DATA is my instance name.

i resolved the connection issue but now i am getting diffrent type of
error
SQLState = HY000, NativeError = 0
Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
NULL

pls help

from
doller



John Bell wrote:
Show quoteHide quote
> Hi
>
> This assumed that EPI-IT-SUFIAN\SQL_DATA was the database server if not
> please let us know what it is supposed to be!
>
> You can check the format and parameters of the BCP utility in books online.
>
> John
>
> "John Bell" wrote:
>
> > Hi
> >
> > Assuming epinav.dbo.Sp_who_Perocess  is a table or view, you should get the
> > command working from a command prompt and then fit that into the xp_cmdshell
> > call.
> >
> > Try the following adding the correct loginid and password:
> >
> > exec master..xp_cmdshell ' BCP  "epinav.dbo.Sp_who_Perocess" in
> > "c:\Sp_who_Perocess.bcp" -n -S "EPI-IT-SUFIAN\SQL_DATA" -U {loginid} -P
> > {password}'
> >
> > John
> >
> >
> > "doller" wrote:
> >
> > > Dear all,
> > >
> > > I created a BCP file from SQL Server2000 with .BCP Extension.
> > > Now i am trying to load data in the SQL Server2005 Database table.
> > > First was getting the error of remote connection which i solved .
> > > Now i am getting this below error
> > >
> > > SQLState = HY000, NativeError = 0
> > > Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> > > NULL
> > >
> > > I am executing this code
> > > exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> > > epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
> > >
> > >  Pls help
> > >
> > > from
> > > Doller
> > >
> > >
Author
15 Mar 2006 12:44 PM
Enric
hi doller,
the following line might be enough (it's been tested from DOS session)

bcp <db>.<table> in <path>.<file> -n -S<server> -U<login> -P<password>
--
current location: alicante (es)


Show quoteHide quote
"doller" wrote:

> Hi all,
>
> EPI-IT-SUFIAN is my server name and SQL_DATA is my instance name.
>
> i resolved the connection issue but now i am getting diffrent type of
> error
> SQLState = HY000, NativeError = 0
> Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> NULL
>
> pls help
>
> from
> doller
>
>
>
> John Bell wrote:
> > Hi
> >
> > This assumed that EPI-IT-SUFIAN\SQL_DATA was the database server if not
> > please let us know what it is supposed to be!
> >
> > You can check the format and parameters of the BCP utility in books online.
> >
> > John
> >
> > "John Bell" wrote:
> >
> > > Hi
> > >
> > > Assuming epinav.dbo.Sp_who_Perocess  is a table or view, you should get the
> > > command working from a command prompt and then fit that into the xp_cmdshell
> > > call.
> > >
> > > Try the following adding the correct loginid and password:
> > >
> > > exec master..xp_cmdshell ' BCP  "epinav.dbo.Sp_who_Perocess" in
> > > "c:\Sp_who_Perocess.bcp" -n -S "EPI-IT-SUFIAN\SQL_DATA" -U {loginid} -P
> > > {password}'
> > >
> > > John
> > >
> > >
> > > "doller" wrote:
> > >
> > > > Dear all,
> > > >
> > > > I created a BCP file from SQL Server2000 with .BCP Extension.
> > > > Now i am trying to load data in the SQL Server2005 Database table.
> > > > First was getting the error of remote connection which i solved .
> > > > Now i am getting this below error
> > > >
> > > > SQLState = HY000, NativeError = 0
> > > > Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> > > > NULL
> > > >
> > > > I am executing this code
> > > > exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> > > > epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
> > > >
> > > >  Pls help
> > > >
> > > > from
> > > > Doller
> > > >
> > > >
>
>
Author
16 Mar 2006 2:31 AM
doller
Hi ,

Thanks for all ur help.
I was getting the error unable to open the BCP file because i was using
-U -P as i was working on the server means with trustedconnection so i
have to use -T in place of  -U and -P

from
Doller



Enric wrote:
Show quoteHide quote
> hi doller,
> the following line might be enough (it's been tested from DOS session)
>
> bcp <db>.<table> in <path>.<file> -n -S<server> -U<login> -P<password>
> --
> current location: alicante (es)
>
>
> "doller" wrote:
>
> > Hi all,
> >
> > EPI-IT-SUFIAN is my server name and SQL_DATA is my instance name.
> >
> > i resolved the connection issue but now i am getting diffrent type of
> > error
> > SQLState = HY000, NativeError = 0
> > Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> > NULL
> >
> > pls help
> >
> > from
> > doller
> >
> >
> >
> > John Bell wrote:
> > > Hi
> > >
> > > This assumed that EPI-IT-SUFIAN\SQL_DATA was the database server if not
> > > please let us know what it is supposed to be!
> > >
> > > You can check the format and parameters of the BCP utility in books online.
> > >
> > > John
> > >
> > > "John Bell" wrote:
> > >
> > > > Hi
> > > >
> > > > Assuming epinav.dbo.Sp_who_Perocess  is a table or view, you should get the
> > > > command working from a command prompt and then fit that into the xp_cmdshell
> > > > call.
> > > >
> > > > Try the following adding the correct loginid and password:
> > > >
> > > > exec master..xp_cmdshell ' BCP  "epinav.dbo.Sp_who_Perocess" in
> > > > "c:\Sp_who_Perocess.bcp" -n -S "EPI-IT-SUFIAN\SQL_DATA" -U {loginid} -P
> > > > {password}'
> > > >
> > > > John
> > > >
> > > >
> > > > "doller" wrote:
> > > >
> > > > > Dear all,
> > > > >
> > > > > I created a BCP file from SQL Server2000 with .BCP Extension.
> > > > > Now i am trying to load data in the SQL Server2005 Database table.
> > > > > First was getting the error of remote connection which i solved .
> > > > > Now i am getting this below error
> > > > >
> > > > > SQLState = HY000, NativeError = 0
> > > > > Error = [Microsoft][SQL Native Client]Unable to open BCP error-file
> > > > > NULL
> > > > >
> > > > > I am executing this code
> > > > > exec master..xp_cmdshell ' BCP  c:\Sp_who_Perocess.bcp in
> > > > > epinav.dbo.Sp_who_Perocess  -n -"EPI-IT-SUFIAN\SQL_DATA" -U -P'
> > > > >
> > > > >  Pls help
> > > > >
> > > > > from
> > > > > Doller
> > > > >
> > > > >
> >
> >

Bookmark and Share