摘要: SELECT 'EXEC sys.sp_addextendedproperty @name=N'||chr(39) ||'MS_Description'||chr(39) ||', @value=N'||chr(39)||COMMENTS||chr(39)||', @level0type=N'||c... 阅读全文
posted @ 2015-02-13 15:57 流浪狗的独白 阅读(227) 评论(0) 推荐(0) 编辑
摘要: if exists ( select * from dbo.sysobjects where id = object_id(N'[dbo].[TableSpace]') and objectproperty(id, N'IsUserTable') = 1 ) drop table [dbo].[T... 阅读全文
posted @ 2015-02-13 15:50 流浪狗的独白 阅读(307) 评论(0) 推荐(0) 编辑
摘要: --查询相同数据select [字段名]或[*]from [表名称1]intersectselect [字段名]或[*]from [表名称2]--查询不同数据select [字段名]或[*]from [表名称1]exceptselect [字段名2]或[*]from [表名称] 阅读全文
posted @ 2015-02-13 15:42 流浪狗的独白 阅读(1335) 评论(0) 推荐(1) 编辑