本文共 592 字,大约阅读时间需要 1 分钟。
CODE:
USE Sales;GO/*CREATE TABLE Orders( OrderID int IDENTITY(1,1) PRIMARY KEY, OrderGUI uniqueidentifier ROWGUIDCOL NOT NULL DEFAULT NEWID(), OrderDate datetime, Sendto varchar(40));INSERT INTO Orders(OrderDate, Sendto)VALUES ('2008-1-1','Jinan City, China'), ('2008-2-19','BeiJing City, China');CREATE TABLE #MyTempTable(cola int PRIMARY KEY);INSERT INTO #MyTempTable VALUES(1);GOSELECT * FROM #MyTempTable;*/DECLARE @TableVar TABLE(Cola int PRIMARY KEY, Colb char(3))INSERT INTO @TableVar VALUES(1, 'abc')INSERT INTO @TableVar VALUES(2, 'def')SELECT * FROM @TableVar
截图:
转载地址:http://tygxx.baihongyu.com/