hash matching

  • I am having an issue with SQL Server 7. It seems that when our production db is being hit hard, a certain query that we run(SELECT with a number of joins) decides it will use hash matching(which is slower). When you run this query when no one is on the system, it uses the primary key to scan. Also, you can run the query against the test system(identical to production but no one is logged into it) and it will not do hash matching. Is there a known issue with SQL 7 where it starts to do hash matching when it is hit hard?

  • To my knowledge no. Is this code in a stored procedure? If so it could be a cached plan causing this, try recompiling. Also can you post the test version of the execution plans if this is not the case so I can understand the differences between the cases you discuss?

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

  • How can I post the showplan as an atatchment(it does not format correctly in this space)? Is that all you need to look at?

  • Just email it to me. I will look at it tomorrow.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply