Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

create table course ( course _ id varchar ( 8 ) , title varchar ( 5 0 ) , dept _ name varchar ( 2

create table course
(course_id varchar(8),
title varchar(50),
dept_name varchar(20),
credits numeric(2,0) check (credits >0),
primary key (course_id),
constraint course1 foreign key (dept_name) references department(dept_name)
on delete set null
);
create table instructor
(ID varchar(5),
name varchar(20) not null,
dept_name varchar(20),
salary numeric(8,2) check (salary >29000),
primary key (ID),
constraint instructor1 foreign key (dept_name) references department(dept_name)
on delete set null
);
create table section
(course_id varchar(8),
sec_id varchar(8),
semester varchar(6)
check (semester in ('Fall', 'Winter', 'Spring', 'Summer')),
year numeric(4,0) check (year >1701 and year <2100),
building varchar(15),
room_number varchar(7),
time_slot_id varchar(4),
primary key (course_id, sec_id, semester, year),
constraint section1 foreign key (course_id) references course(course_id)
on delete cascade,
constraint section2 foreign key (building, room_number)
references classroom(building, room_number)
on delete set null
);
Referring to and tables. Code an SQL statement that,
Gives the course ID, section, title, semester, building, and room for courses offered in Fall 2023. Order the result by course ID and then section.
Copy

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

More Books

Students also viewed these Databases questions

Question

Explain the factors that determine the degree of decentralisation

Answered: 1 week ago

Question

What Is acidity?

Answered: 1 week ago

Question

Explain the principles of delegation

Answered: 1 week ago

Question

State the importance of motivation

Answered: 1 week ago

Question

Discuss the various steps involved in the process of planning

Answered: 1 week ago

Question

Are there any changes you would recommend in the selection process?

Answered: 1 week ago