A data analyst runs the following command: INSERT INTO stakeholders.suppliers TABLE stakeholders.new_suppliers; What is the result of running this command?
A.
The suppliers table now contains both the data it had before the command was run and the data from the new_suppliers table, and any duplicate data is deleted.
B.
The command fails because it is written incorrectly.
C.
The suppliers table now contains both the data it had before the command was run and the data from the new_suppliers table, including any duplicate data.
D.
The suppliers table now contains the data from the new_suppliers table, and the new_suppliers table now contains the data from the suppliers table.
E.
The suppliers table now contains only the data from the new_suppliers table.
Try the following code, you will see that it runs without a problem:
DROP TABLE IF EXISTS test;
CREATE TABLE test (id INT, name VARCHAR(64));
INSERT INTO test VALUES
(1, 'Person1'),
(2, 'Person2');
-- SELECT * FROM test;
DROP TABLE IF EXISTS test2;
CREATE TABLE test2 (id INT, name VARCHAR(64));
INSERT INTO test2 VALUES
(3, 'Person3'),
(4, 'Person4');
-- SELECT * FROM test2;
INSERT INTO test TABLE test2;
SELECT * FROM test
upvoted 2 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Ayush24
7 months, 2 weeks agolibbster
8 months, 1 week agoDevscope
10 months ago