2012年11月15日

对于msSql中exists操作符求值的疑惑

摘要: 看SQL.Server.2008编程入门经典(第3版).pdf这书时.其中page 169中说到用exists关键字时.不需要一行行地查找.只要找到一行符合条件的记录就返回true也就是优势在于不用扫整张的表.可是我用下面的两组语句去扫表却得不出这个结论1.if exists( select 1 from M_DynamicConfig where nodeid = 5242881 or nodeid & 0xfff80000 = 5242881)beginprint 'y'end2.if exists( select 1 from M_DynamicConfig wh 阅读全文

posted @ 2012-11-15 10:52 Orz.. 阅读(433) 评论(0) 推荐(0)

导航