Join hints
forces physical join strategy
What changes
- Input
- none
- Output or change
- none
Syntax at a glance
<join_hint> ::= { LOOP | HASH | MERGE | REMOTE | REDUCE | REPLICATE | REDISTRIBUTE [(columns count)]}
Work example
A measured join-plan issue needs one algorithm hint tested against SQL Server's default choice.
Capture the unhinted plan, reads, and runtime. Test one join hint with representative row counts and parameter values.
Check your work Join hints. The intended join algorithm appears and result rows remain unchanged across the comparison.
Open Microsoft Learn for full syntax, permissions, and details for your version.