Question: Let tables PART and PART_STRUCTURE be defined as follows: CREATE TABLE PART (P# P#, DESCRIPTION CHAR(100), PRIMARY KEY (P#)); CREATE TABLE PART STRUCTURE ( MAJOR

Let tables PART and PART_STRUCTURE be defined as follows: CREATE TABLE PART (P# P#, DESCRIPTION CHAR(100), PRIMARY KEY (P#)); CREATE TABLE PART STRUCTURE ( MAJOR P#, P#, MINOR P# P#, QTY QTY, PRIMARY KEY (MAJOR_P#, MINOR P#), FOREIGN KEY (MAJOR_P#) REFERENCES PART, FOREIGN KEY (MAJOR_P#) REFERENCES PART); Table PART_STRUCTURE shows which parts (MAJOR_P#) contain which other parts (MINOR_P#) as first level components. Write an SQL program to list all component parts of a given part, to all levels .

Step by Step Solution

3.42 Rating (155 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Let tables PART and PARTSTRUCTURE be defined as follows CREATE TABLE PART P P DESCRIPTION CHAR100 PRIMARY KEY P CREATE TABLE PART STRUCTURE MAJOR P P MINOR P P QTY QTY PRIMARY KEY MAJORP MINOR P FOREI... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Document Format (1 attachment)

Word file Icon

CS-DB (28).docx

120 KBs Word File

Students Have Also Explored These Related Databases Questions!