Hi gurus,
I just started to look at a very slow-running SQL statement
generated by an application (Siebel). I spooled the SQL from the
application, replaced the bind variables by their values, and tuned
from the Query Analyser. But after awhile, I realized that the
statement using bind variables and the same statement using the values
instead of the bind variables often have completely different
execution plans! Is that normal? Can someone tell me how the SQL
Server treats bind variables. Don't worry about being too technical,
I'm an Oracle DBA/developer.
Thanx
Daniel
I just started to look at a very slow-running SQL statement
generated by an application (Siebel). I spooled the SQL from the
application, replaced the bind variables by their values, and tuned
from the Query Analyser. But after awhile, I realized that the
statement using bind variables and the same statement using the values
instead of the bind variables often have completely different
execution plans! Is that normal? Can someone tell me how the SQL
Server treats bind variables. Don't worry about being too technical,
I'm an Oracle DBA/developer.
Thanx
Daniel
Comment