SQL INSERT INTO SELECT Keyword
Clash Royale CLAN TAG#URR8PPP
<!--
main_leaderboard, all: [728,90][970,90][320,50][468,60]-->
SQL INSERT INTO SELECT Keyword
❮ SQL Keywords Reference
INSERT INTO SELECT
The INSERT INTO SELECT
command copies data
from one table and inserts it into another table.
The following SQL copies "Suppliers" into "Customers" (the columns
that are not filled with data, will contain NULL):
Example
INSERT INTO Customers (CustomerName,
City, Country)
SELECT SupplierName, City, Country FROM Suppliers;
Try it Yourself »
The following SQL copies "Suppliers" into "Customers" (fill all
columns):
Example
INSERT INTO Customers (CustomerName, ContactName, Address, City, PostalCode,
Country)
SELECT SupplierName, ContactName, Address, City, PostalCode,
Country FROM Suppliers;
Try it Yourself »
The following SQL copies only the German suppliers into "Customers":
Example
INSERT INTO Customers (CustomerName,
City, Country)
SELECT SupplierName, City, Country FROM Suppliers
WHERE Country='Germany';
Try it Yourself »
❮ SQL Keywords Reference