今天重装了SQL,装完后发现以前用的一个导出文本的命令不好使了,请各位大虾帮我看看是怎么回事.先谢谢EXEC master..xp_cmdshell 'bcp
"select e,f,g from sd..mbdz group by e,f,g
where e!=15 and
fc=(select count(*) from sd..mbdz where e=15 group by e)*1 "
queryout f:\efg.txt -c -t, -U -Ppassword'
提示错误:
'bcp' 不是内部或外部命令,也不是可运行的程序
或批处理文件。
NULL
看这个
'bcp "select e,f,g from sd..mbdz where e!=15 and fc=(select count(*) from sd..mbdz where e=15 group by e)*1 group by e,f,g "
queryout f:\efg.txt -c -T'
右击我的电脑->属性->高级->环境变量->看看Path有没有SQL SERVER安装目录下的Bin路径.没有.就加上.