【发布时间】:2011-03-17 08:00:28
【问题描述】:
如果表包含超过 700,000 行,确定项目是否存在的最佳性能是什么
if (Select count(id) from Registeration where email='email@w.cn') > 0
print 'Exist'
else
print 'Not Exist'
或
if Exists(Select id from Registeration where email='email@w.cn')
print 'Exist'
else
print 'Not Exist'
【问题讨论】:
标签: sql sql-server-2005 performance tsql