
Ultimate access to all questions.
Which of the following SQL commands can be used to append the new record to an existing Delta table my.table?
A
INSERT INTO my table VALUES ('a1',6,9.4)
B
my table UNION VALUES ('a1', 6,9.4)
C
INSERT VALUES ('a1',6, 9.4) INTO my_table
D
UPDATE my_table VALUES ('a1', 6, 9.4)
E
UPDATE VALUES ('a1',6, 9.4) my table
Explanation:
The correct answer is A because:
INSERT INTO table_name VALUES (...) is the correct way to insert a single row of dataUNION is used to combine results from multiple SELECT statements, not to insert dataINSERT VALUES should be INSERT INTOUPDATE is used to modify existing records, not to insert new onesIn Databricks Delta tables, you can use standard SQL INSERT INTO statements to append data to existing tables. The command preserves the existing data while adding new records.