bcp dump prompting for password - going nuts here

  • command:

    C:>bcp hrdb..employee_table out c:\temp\test.csv -t, -T

    Produces:

    Password:

    CTLIB Message: - L6/O8/S5/N3/5/0:

    ct_connect(): directory service layer: internal directory control layer error: Requested server name not found.

    Establishing connection failed.

    C:>

    I have tried this locally at the server, remotely, and through T-SQL

    When run as a scheduled job (not manually running the job) the dump works however I am unable to run it manually.

    I have tried as many variations on the naming as I can think of, and have included the -Ssql01 for the server flag.

    Any suggestions?

  • found the issue

    The box has the Sybase drivers on it.

    It overwrote the machines environment variable to the location of bcp.exe.

    Sybase's bcp is different than SQL's bcp

    I knew I wasn't going crazy...

  • Many thanks, I had the same problem, your post help a lot :D.

  • I just ran into this yesterday, got fed up and used EM to import my file. Thanks for the info.


  • Thank you for your post. I ran into this issue now. Could you let me know how to fix it? Uninstall sybase driver? or some way to configure my SQL server? Actually I need sybase driver for now.

  • Thanks a lot

    I changed my batch file as follows.

    cd"C:\Program Files\Microsoft SQL Server\90\Tools\Binn\bcp.exe" ........

    This resolved my issue.

  • This Issue was killing me for the past couple of days...

    After removing the Sybase Bin foldder path from PATH variable,it worked as expected...

    Many thanks to all 🙂

  • I think I must be the dumbest guy ou there, I am still struggling with this. I am not using a batch file I am entering it directly into cmd C:\Program Files\Microsoft SQL Server\80\Tools\Binn\bcp adventureworks2008.sales.currency out "E mod05\labfiles\currency.dat" -T -c and it still asks me for a password what am I still doing wrong

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply