问题:
When I run a query with OPENROWSET
in SQL Server 2000 it works. 当我在SQL Server 2000中使用OPENROWSET
运行查询时,它可以工作。
But the same query in SQL Server 2008 generates the following error: 但是SQL Server 2008中的相同查询会生成以下错误:
SQL Server blocked access to STATEMENT 'OpenRowset/OpenDatasource' of component 'Ad Hoc Distributed Queries' because this component is turned off as part of the security configuration for this server. SQL Server阻止访问组件“Ad Hoc Distributed Queries”的STATEMENT“OpenRowset / OpenDatasource”,因为此组件已作为此服务器的安全配置的一部分关闭。 A system administrator can enable the use of 'Ad Hoc Distributed Queries' by using sp_configure 系统管理员可以使用sp_configure启用“Ad Hoc Distributed Queries”