cencenhai 发表于 2016-11-2 07:39:07

sql server导出数据到Excel

  执行语句: 
  EXEC master..xp_cmdshell 'bcp test.dbo.Table1 out c:\dd\Temp.xls -c -q -S".\SQLEXPRESS" -U"sa" -P"123"'
  
  出错解决方法: 
  exec sp_configure 'show advanced options',1
reconfigure
  exec sp_configure 'xp_cmdshell',1
reconfigure
页: [1]
查看完整版本: sql server导出数据到Excel