0% found this document useful (0 votes)
19 views6 pages

Rdbms Question Paper

Uploaded by

Ajay Seenu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views6 pages

Rdbms Question Paper

Uploaded by

Ajay Seenu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6

SET – 1

Create a Supplier table as shown below with the following constraints :


1. Sup_No (primary key)
2. Item-Price (not null)

 Write SQL query to display Suplier numbers and Supplier names whose name starts with ‘R’
 Write SQL query to display the name of suppliers who supply Processors and whose city is Delhi.
 Write SQL query to display the names of suppliers who supply the same items as supplied by .
 Ramesh.
 Write SQL query to increase the price of Keyboard by 200.
 Write SQL query to display supplier numbers, Suplier names and itemprice for suppliers in delhi
in the ascending order of itemprice.
 Write SQL query to add a new column called CONTACTNO
 Write SQL query to delete the record whose itemprice is the lowest of all the items supplied .
 Write SQL query to display the records of suppliers who supply items other than Processor or
Keyboard.

-----------------------------------------------------------------------------------------------------------------------------------
Write the user defined function to find biggest among three numbers
-----------------------------------------------------------------------------------------------------------------------------------
SET - 2

 Write SQL query to display all the employees who earn more than average salary of all the
employees in the company.
 Write SQL query to display the fields Eid, Ename and Dname.
 Write SQL query to sort the employee table in the descending order of salaries.
 Write SQL query to list all the job designations in the employee table without repetitions.
 Write SQL query to display all the employee details Department wise and in the ascending
order of their salaries.
 Write SQL query to display all the clerks in DeptId D2.
 Write SQL query to display all the employees whose salary is between 30000 and 45000.
 Write SQL query to display all the employee details along with their work experience in the
company till current date.

-----------------------------------------------------------------------------------------------------------------------------------
Write PL/SQL program to copy the contents (Eid, Ename, DeptId) into to Manager table who are the
Managers
-----------------------------------------------------------------------------------------------------------------------------------
SET – 3

Constraints : Sid (Primary Key), Sname (not null), Gender (Check)

 Write SQL query to display the students who are not from Telangana or AndhraPradesh.
 Write SQL query to display all the female students enrolled under Comp course and who belong
to OBC.
 Write SQL query to display the student ids, names, and their present age.
 Write SQL query to display the students in the ascending order of their names for each course.
 Write a SQL query to add two new columns Contactno and Email to the existing fields.
 Write an SQL query to display all the Student names where the length of the name is 5
characters.

-----------------------------------------------------------------------------------------------------------------------------------
Write a trigger program to insert record in Admission table while admitting a new student in Student
Table
-----------------------------------------------------------------------------------------------------------------------------------
SET - 4

Constraints : BookId (primary key), BookName (not null), Price(less than 1000)

 Write SQL query to display the list of authors from Himalaya publications.
 Write SQL query to display the total cost of books purchased Publisher wise.
 Write SQL query to count the total number of books under Kalyani publications.
 Write SQL query to rename the column Publisher as Publications.
 Write SQL query to display the books whose price is between 500 and 700
 Write SQL query to increase the price of all the books by 200 for publishers other than Himalaya
or Kalyani.
 Write SQL query to display the book details where author name contains the name Sharma.
 Create a view to display the fields BookId and BookName where the Publisher is Himalaya.

-----------------------------------------------------------------------------------------------------------------------------------
Write Exception handling program to display Not found message if the particular book is not
available
-----------------------------------------------------------------------------------------------------------------------------------
SET – 5

1. Create a Collection in MongoDB with the following field

2. Insert new data (S7, Sundar, Printer, 6000, Chennai)


3. Delete the S3 from the collection
4. Change the Printer price into 7000

-----------------------------------------------------------------------------------------------------------------------------------
Write a cursor program to display the items supplied to the city “Delhi”
-----------------------------------------------------------------------------------------------------------------------------------
SET – 6

1. Demonstrate the use of GROUP BY and HAVING clauses with suitable examples.
2. Demonstrate the JOINs with suitable illustrative examples.
3. Write a PL/SQL program to display even numbers from 100 to 200

-----------------------------------------------------------------------------------------------------------------------------------
Draw E R Diagram for Library Management System
-----------------------------------------------------------------------------------------------------------------------------------

SET ALOTMENT

SET-NO. Reg.Nos
1 1 13 25 37
2 2 14 26 38
3 3 15 27 39
4 4 16 28 40
5 5 17 29 41
6 6 18 30 42

1 7 19 31
2 8 20 32
3 9 21 33
4 10 22 34
5 11 23 35
6 12 24 36

You might also like