0
Insert into and select
Put a new row with insert into and then select
3 ответов
+ 3
First learn SQL about insert
0
Done, now what?
0
There's two main ways to insert using select. The first can be used on existing tables and the second only works to create a table. I think the second one only works on temp tables but I havent confirmed.
INSERT INTO schema.table (col1, col2, ...)
SELECT col1, col2, ... FROM schema.other_table WHERE modifier_column = [value]
Or
SELECT col1, col2, ...
INTO #table
FROM schema.other_table
WHERE modifier_column = [value]