关于定义布尔值的变量
declare @ss bitset @ss= exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[cgjggz]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
为何上面在查询分析器中执行会出错首乌,而下面的语句则不会
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[cgjggz]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
select * from cgjggz
[此贴子已经被作者于2016-9-23 09:39编辑过]