How can I get the actual rows?
I get a error : Query execution failed. This syntax is only allowed for parameterized queries. Must declare the scalar variable '@P1'.
Let me refine the question, the sniffed parameters is included in the query plan, and plan explorer knows about it. I only want plan explorer to declare or substitute the variables automatic. I know I can do it manually and then it will work. But could it be done automatic?
What Exactly Does the Query Optimizer Consider with Parallel Plans?