标签:tab bsp nbsp 变量 dai eid declare before har
INSERT INTO TestTB(Province,City) output inserted.Province, inserted.City VALUES(‘广东‘,‘深圳‘)
delete from TestTB output deleted.* where id=1
UPDATE TestTB SET Province = ‘湖南‘,City=‘郴州‘ OUTPUT ‘我来自(更新前)‘+ DELETED.Province+DELETED.City as [Before] ,‘我来自(更新后)‘ + Inserted.Province+Inserted.City as [After] WHERE id=1
DECLARE @temp TableTABLE( idint, Provincevarchar(50), Cityvarchar(50) )DELETEFROMTestTB OUTPUT deleted.*INTO@tempTableWHEREid>4SELECT*FROM@tempTable
标签:tab bsp nbsp 变量 dai eid declare before har
原文地址:http://www.cnblogs.com/mr-yang-localhost/p/6683297.html