日期:2014-05-17  浏览次数:20538 次

使用xp_cmdshell命令时报错
执行xp_cmdshell时报错
“命令提示符已被系统管理员停用。请按任意键继续. . . ”
但我在windows 2003下的[运行]下输入cmd是可以出来的,什么原因?

------解决方案--------------------

sp_configure 'xp_cmdshell',1
go
reconfigure

------解决方案--------------------
需重新配置
exec sp_configure 'show advanced options',1
reconfigure
exec sp_configure 'xp_cmdshell' ,1
reconfigure
exec xp_cmdshell '命令'
exec sp_configure 'xp_cmdshell' ,0
reconfigure
exec sp_configure 'show advanced options',0
reconfigure