Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

c ) ALTER TABLE WORKS _ ON ADD CONSTRAINT FK 1 FOREIGN KEY ( Essn ) REFERENCES EMPLOYEE ( Ssn ) ; d ) None

c) ALTER TABLE WORKS_ON ADD CONSTRAINT FK1 FOREIGN KEY (Essn) REFERENCES
EMPLOYEE (Ssn);
d) None of the above.
Consider the following relation schema:
PRODUCT
Which of the following statements creates the above relation?
a) CREATE TABLE PRODUCT (
PID INT CHECK(PID BETWEEN 1 AND 1000), UNIQUE(Name),
Name VARCHAR(20) NOT NULL , PRIMARY KEY (PID),
Color VARCHAR(5) DEFAULT 'White' CHECK(Color IN('Red', 'Green', 'Blue',
'White')));
b) CREATE TABLE PRODUCT (
PID INT PRIMARY KEY CHECK PID >0,
Name VARCHAR(20) NOT NULL UNIQUE,
Color VARCHAR(5) DEFAULT 'White' CHECK(Color IN('Red', 'Green', 'Blue',
'White')));
c) CREATE TABLE PRODUCT (
PID INT PRIMARY KEY CHECK(PID>0 AND PID=1000),
Name VARCHAR(20) REQUIRED UNIQUE,
Color VARCHAR(5) DEFAULT 'White' CHECK(Color IN('Red', 'Green', 'Blue',
'White')));
d) None of the above.
Consider the following database state and SQL query.
SALESMAN
SELECT NAME
FROM SALESMAN
WHERE CITY IN ('Paris', 'Cairo' );
Which of the following represents the result of the above SQL query?
a)
b)
c)
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL/PHP Database Applications

Authors: Jay Greenspan, Brad Bulger

1st Edition

ISBN: 978-0764535376

More Books

Students also viewed these Databases questions