[已关闭问题]
declare @CustomerID uniqueidentifier
<P><BR>set @CustomerID = '129F1B78-5373-4196-BE92-253762896ADB' </P>
<P> </P>
<P><BR>select a.* from opvoucher a <BR>WHERE (a.customercode = @CustomerID or @CustomerID is null ) </P>
<P> </P>
<P><BR>select a.* from opvoucher a <BR>WHERE (a.customercode = @CustomerID) </P>
<P> </P>
<P>为何 前一句 where子句利用不到索引?</P>
<P> </P>
阿福
|
菜鸟二级
|
园豆:
250
提问于:2008-07-30 15:14