Question: what are ad hoc distributed queries?
Answer: When the ad hoc distributed queries option is set to 1 , SQL Server allows ad hoc access against other providers. When it is set to 0 , SQL Server does not allow any ad hoc access. Ad hoc distributed queries use the OPENROWSET and OPENDATASOURCE functions to connect to remote data sources using OLE DB.