Home > Archive > MS SQL Server > February 2006 > BCP newbie question









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author BCP newbie question
Chris

2006-02-09, 8:23 pm

I am trying to run the bcp utility. When I run it from the command prompt it
works. When I try it from a bat it goes into this crazy endless loop
repeating the command again and again. Any ideas what I am doing wrong?
Regards, Chris.

bcp pubs..publishers out C:\test.txt -c -U****** -P***** -S******
pause


Dan Guzman

2006-02-10, 3:23 am

Is your command file by chance named BCP.BAT or BCP.CMD? In that case, it's
calling itself rather than BCP.EXE. You can remedy the problem by
specifying BCP.EXE and/or using a different name for you command file. It's
a good practice to avoid naming command files the same as EXE or command
names.

--
Hope this helps.

Dan Guzman
SQL Server MVP

"Chris" <123@123.com> wrote in message
news:OO3%23CBbLGHA.1124@TK2MSFTNGP10.phx.gbl...
>I am trying to run the bcp utility. When I run it from the command prompt
>it
> works. When I try it from a bat it goes into this crazy endless loop
> repeating the command again and again. Any ideas what I am doing wrong?
> Regards, Chris.
>
> bcp pubs..publishers out C:\test.txt -c -U****** -P***** -S******
> pause
>
>



Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2009 droptable.com