2014-09-06

TSQL - Enable OPENROWSET

Symptom:
Msg 15281, Level 16, State 1, Line 1
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. A system administrator can enable the use of 'Ad Hoc Distributed Queries' by using sp_configure. For more information about enabling 'Ad Hoc Distributed Queries', search for 'Ad Hoc Distributed Queries' in SQL Server Books Online.



Fix:
sp_configure 'show advanced options',1
reconfigure with override
go

sp_configure 'Ad Hoc Distributed Queries',1
reconfigure with override
go


If after this you still get an error about name pipes, enable them.
https://www.blackbaud.com/files/support/infinityinstaller/content/installermaster/tkenablenamedpipesandtcpipconnections.htm


No comments:

Post a Comment