Posts

Showing posts from July, 2024

RDBMS IMPORTANT QUESTIONS

 RDBMS IMPORTANT QUESTIONS: 1)Define DBMS 2)What is the role of the primary key? 3)What is a normalization? 4)Write the use of the ER model? 5)What is the general meaning of outer join?  6)What are the basic DDL Commands available in DBMS?  7)Define Database. 8)What is the subform? 9)define data dictionary. 10)strong Entity vs weak entity 5 marks:                                  1)What are the components of database System? 2discuss about ER-Model 3)Explain about objective of the DBMS? 4) Write short notes on DDL statements. 5)What are the difference between ORDERBY and GROUPBY Command 6)Write a short notes about subqueries      7)Funtions of database administrator 10 mark:       1)DDL Commands with example. 2)DML Commands with example                           ...

RDBMS EXERCISES2

  RDBMS EXERCISES CONTINUED.... EXERCISE 4: Create a table called Employee with the following structure. Empno (Number), Ename (Varchar2(20)), Job (Varchar2(20) ), Sal (Number)  (i) Add a column DoJ (DATE) with the Employee table.  (ii) Insert any five records into the table.  (iii) Update the column details of job  (iv) Rename the column Sal as Emp_Salary of Employ table using alter command.  (v) Delete the employee whose empno is 101. ANSWER: Create the Employee Table SQL> CREATE TABLE Employee (     Empno NUMBER PRIMARY KEY,     Ename VARCHAR2(20),     Job VARCHAR2(20),     Sal NUMBER ); (i) Add a Column DoJ (DATE) to the Employee Table SQL> ALTER TABLE Employee ADD DoJ DATE; (ii) Insert Any Five Records into the Table SQL> INSERT INTO Employee (Empno, Ename, Job, Sal, DoJ) VALUES (100, 'Alice', 'Developer', 50000, TO_DATE('2020-01-15', 'YYYY-MM-DD')); ...

RDBMS EXERCISES

  RDBMS  EXERCISES EXERCISE 1: Using Employee Database with two tables. Employee_Personal_details as parent table with NOT NULL and UNIQUE constraints for Employee_ID and NOT NULL for age with Employee ID as primary key. Also create another table Employee_Salary_details as child table with reference of Employee_ID as foreign key. Use DDL commands create and alter. Also create   Also perform the following queries   (i) Determine the names of employee, who earn more than 20000.   (ii) Determine the names of employees, who take highest salary in their departments.   (iii) Determine the employees, who are located at the same place.   (iv) Determine the employees, whose total salary is like the minimum salary of any department.   (v) Determine the department which does not contain any employees.   ANSWER: EMPLOYEE-PERSONAL DETAILS TABLE: CREATE TABLE Employee_Personal_details ( Employee_ID INT PRIMARY KEY, Name VARCHAR(100) N...