Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 15930

Usage of SQL Server Query Hints

$
0
0

Hi all,

I am using sql server 2017, and I was trying to optimize a query that runs slowly. Surfing some blogs, I came across query hints and used this one:

option(use hint('DISABLE_OPTIMIZED_NESTED_LOOP'), maxdop 1);

Unfortunately, what happened is now the query runs even slower, and I couldn't figure out how to reverse the effect of this hint.

My questions would be:

1- Does this hint affect other users and their queries too ?? 

2- How to restore the query optimizer to its default settings ??

I appreciate you help in this matter.

Best Regards


Viewing all articles
Browse latest Browse all 15930

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>