Click here to Skip to main content
15,907,687 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
i work on SQL server 2014 windows 7 64bit
when transfer data using bcp it not transfer data to file i created
i open database the new query then write command below
i get following
'BCP' is not recognized as an internal or external command,
operable program or batch file.

so what i do to run transfer data by using bcp

What I have tried:

EXEC master..xp_cmdshell 'BCP OUT D:\SOQueryOut.txt -T -c'
Updated 30-Mar-20 21:22pm

1 solution

At a guess the command shell "path" environment variable doesn't contain the SQL Server binaries folder.
Check it:
EXEC master..xp_cmdshell 'ECHO %path% >C:\temp\pathvariable.txt'
And look at the path data it saves.

Probably, your SQL Server server needs to have been rebooted since an SQL Server update, and this hasn't happened.
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900