SQL server indexed temp table
IF (SELECT object_id('TempDB..#TempTable')) IS NOT NULL
DROP TABLE #TempTable
GO
--
CREATE TABLE #TempTable
(
id int,
name varchar(50),
primary key (id, name)
)
--
INSERT INTO #TempTable
SELECT 1,'name'
--
SELECT * FROM #TempTable
Comments
Post a Comment