how to select insert items into temp table in sql code example
Example: select into temp table
SELECT *
INTO #temp
FROM (
SELECT col1, col2
FROM table1
) AS x
SELECT *
INTO #temp
FROM (
SELECT col1, col2
FROM table1
) AS x