exec sp_configure 'show advanced options',1 RECONFIGURE exec sp_configure 'Ad Hoc Distributed Queries',1 RECONFIGURE