• Well, I can see the difference. I'm interested in knowing if there's a way to improve it.

    When I use a constant in my query, the data is filtered at the first query in the execution plan. This greatly reduces the records upstream. When I use IN (temp), the records are filtered about halfway through the execution.