Posted by Doug on 03/02/06 06:38
Hello,
Thanks for your comments.
An interesting subtlty is involved here. I wonder if the difference is
significant.
Dick's code had and ((@AcctCode = '*' ) or (AcctCode = @Acctcode))
your code had
(indexedcol1 = @vall OR @val1 = '*')
this sounds weird, but I can easily see where your code would require a
table scan, yet Dick's code could be done without one.
Does this make any sense to anyone else?
I don't know how to explain my logic.
Navigation:
[Reply to this message]
|