Which multitable INSERT statement would you use?

The details of the order ID, order date, order total, and customer ID are obtained from the
ORDERS table. If the order value is more than 30000, the details have to be added to the
LARGEjDRDERS table. The order ID, order date, and order total should be added to the
ORDERJHISTORY table, and order ID and customer ID should be added to the
CUSTJHISTORY table. Which multitable INSERT statement would you use?

The details of the order ID, order date, order total, and customer ID are obtained from the
ORDERS table. If the order value is more than 30000, the details have to be added to the
LARGEjDRDERS table. The order ID, order date, and order total should be added to the
ORDERJHISTORY table, and order ID and customer ID should be added to the
CUSTJHISTORY table. Which multitable INSERT statement would you use?

A.
Conditional FIRST INSERT

B.
Conditional ALL INSERT

C.
Pivoting INSERT

D.
Unconditional INSERT



Leave a Reply 2

Your email address will not be published. Required fields are marked *


ming

ming

I don’t understand why A is incorrect

insert first when id = 2
then into cust1 values (id)
into cust2 values (id)
select id from customers;

I think the answer is both A and B.

haon

haon

INSERT FIRST just excute the first true WHEN clause. So the answer is B