select top 1 * from sysobjects
if @@rowcount=1
print '有结果1'select top 1 * from sysobjects where 1>1
if @@rowcount=1
print '有结果2'/*--结果只输出了有结果1