Question: in Sql C. Command Prompt - sqlplus SQL> desc Course Name Null? Type CORSNO CNAME DEPTNO# CMAX NUMBER(3) VARCHAR2 (30) VARCHAR2(2) NUMBER(2) C. Command Prompt





in Sql
C. Command Prompt - sqlplus SQL> desc Course Name Null? Type CORSNO CNAME DEPTNO# CMAX NUMBER(3) VARCHAR2 (30) VARCHAR2(2) NUMBER(2) C. Command Prompt - sqlplus SQL> Name desc DEP Null? Type DEPTNO DNAME NOT NULL VARCHAR2(2) VARCHAR2 (20) CH. Command Prompt - sqlplus SQL> desc Enrolment Name Null? Type STDNO# CORSNO# GRADE EDATE NUMBER(8) NUMBER(3) NUMBER(2) DATE C:S. Command Prompt - sqlplus SQL> desc Stu Name Null? Type STDNO SNAME DEPTNO# NOT NULL NUMBER (8) NOT NULL VARCHAR2(30) VARCHAR2(2) 1) Add the following department to the DEP Table: DEPTNO ='CM' and DNAME = 'Chemistry' 2) Add the following COURSE: (301, 'Chemistry I', 'CM', 40). 3) Try to add the COURSE: (101, 'Introduction to DOS', 'CP', 30). Discuss the result. 4) Try to add the COURSE: (101, 'Introduction to DOS', 'CP', 30). Discuss the result. 5) How many rows are inserted correctly into each of the COURSE and DEP tables? 6) Execute the following SQL Query: SE LE CT * FROM DEP: How many rows you get?...... 7) Execute the following SQL Query: SELECT * FROM COURSE; How many rows you get? 8) Right now, do the rows are permanently inserted into the tables? Discuss. 9) ROLLBACK the transaction. What is happened ? 10) If the rows are not permanently inserted, execute a statement to save the inserted rows. Now suppose we want to empty the two tables DEP and COURSE. 11) DELETE the rows in the DEP table first. Discuss the result and solve the problem to empty the two tables properly. 12) Check that the two tables are empty. 13) Extend the table DEP with a new column NBEMP to store the NUMBER(2) of employees in each department. 14) Remove the two tables DEP and COURSE
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
