DBMS Practice
DBMS Practice
( Dept_ID varchar(5),
Dept_name varchar(20),
Dept_Building varchar(20),
Dept_budget numeric(8,2),
primary key(Dept_ID) );
( course_id varchar(8),
course_title varchar(50) not null,
dept_ID varchar(5),
course_credits numeric(2,0),
primary key (course_id));
( Inst_ID varchar(6),
Inst_Name varchar(20),
Inst_salary numeric(8,2),
Dept_ID varchar(5),
course_ID varchar(8),
primary key(Inst_ID));
5. Change the character type of the Dept_Building in Department table to become Varchar(30).
6. Insert Data into Tables
insert into course values ('238', 'The Music of Donovan', '7', 3);
insert into course values ('608', 'Electron Microscopy', '7', 3);
insert into course values ('539', 'International Finance', '6', 3);
7. Delete from Instructor Table the Instructors whose names begin with ‘T’;
Delete from Instructor
where Inst_Name ….. ;
9. Write SQL query to get all instructors whose names consist of three characters.