Home / Expert Answers / Computer Science / consider-the-same-schema-as-above-given-by-the-following-create-table-statements-create-table-boats-pa203

(Solved): Consider the same schema as above given by the following create table statements.CREATE TABLE Boats ...



Consider the same schema as above given by the following create table statements.

CREATE TABLE Boats (bID INT PRIMARY KEY, bcolor VARCHAR(10);

CREATE TABLE Sailors (sID INT PRIMARY KEY, sName VARCHAR(20), sRating INT);

CREATE TABLE Reservations (bID INT REFERENCES Boats, sID INT REFERENCES Sailors, dateRes DATE,

PRIMARY KEY (bID, sID, dateRes);

Let us assume that we have written a PL/SQL trigger that ensures that any new boat inserted will have bcolor value of one of the primary colors: red, blue or green (you can assume your trigger code from above).

Let us also consider that the boats table has the following data.

bIDbColor
101red
102blue

Will the following INSERT statement succeed or will it give an error? Also, show the Boats table after performing the INSERT statement.

INSERT IGNORE INTO Boats VALUES (103, 'red');



We have an Answer from Expert

View Expert Answer

Expert Answer



We have an Answer from Expert

Buy This Answer $5

Place Order

We Provide Services Across The Globe