0% found this document useful (0 votes)
34 views2 pages

Database Practices Lab

This document outlines the structure and requirements for a database practical end semester examination. It provides 5 questions to assess students' abilities to: 1) Create a PRODUCT table with specified fields and primary key and insert meaningful records. 2) Write SQL queries on the PRODUCT table to retrieve records meeting criteria on price, date fields. 3) Create a database with SUPPLIER, PARTS, SUPPLY PARTS, PROJECTS, ORDERS tables with meaningful data. 4) Write additional SQL queries on this database to find related records between the tables.

Uploaded by

Bhuvanesh
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
Download as docx, pdf, or txt
0% found this document useful (0 votes)
34 views2 pages

Database Practices Lab

This document outlines the structure and requirements for a database practical end semester examination. It provides 5 questions to assess students' abilities to: 1) Create a PRODUCT table with specified fields and primary key and insert meaningful records. 2) Write SQL queries on the PRODUCT table to retrieve records meeting criteria on price, date fields. 3) Create a database with SUPPLIER, PARTS, SUPPLY PARTS, PROJECTS, ORDERS tables with meaningful data. 4) Write additional SQL queries on this database to find related records between the tables.

Uploaded by

Bhuvanesh
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1/ 2

M.E / M.

Tech PRACTICAL END SEMESTER EXAMINATIONS, JANUARY 2023


First Semester

CP4152 - DATABASE PRACTICES LABORATORY


(Regulations 2021)

Time : 3 Hours Answer any one Question Max.Marks100

Aim/Principle/ Tabulation/ Calculation & Viva- Record Total


Procedure/ Program/Drawing/ Results/ Voce
Algorithm/ Flow chart/Schemes/ Inference/
Techniques Methods Observations
30 25 25 10 10 100
1 Create the following table with the fields given below:
PRODUCT (P_ID, Model, Price, Name, Date_of Manufacture, Date_of_Expiry)
Use appropriate data types for all the fields. Select appropriate primary key. Insert
at least 10 meaningful records in the table.

2. For the table designed in question number 1 above, answer the following queries
using SQL:
(a) Display name and date_of_expiry of all the products whose price is more than
500.
(b) Display name, product ID and price of all the products whose
date_of_manufacture is after "01-01-2018".
(c) Display name and date_of_manufacture and date_of_expiry of all the products
whose price is between 5,000 and 10,000.
(d) Display name, product ID and model of all the products which are going to
expire after two months from today.

3. Create the following database defined below:


SUPPLIER (Supplier #, Company Name, City)
PARTS (Part #, Weight)
SUPPLY PARTS (Supplier #, Part #)
PROJECTS (Project rt #, Quantity) #, Part
ORDERS (Part#, Supplier #, Date of Delivery)
Select appropriate datatypes for each of the fields. Input meaningful data of at
least 10 records.

4. Create the following table with the fields given below:


PRODUCT (P_ID, Model, Price, Name, Date_of Manufacture, Date_of Expiry)
Use appropriate data types for all the fields. Select appropriate primary key. Insert
at least 10 meaningful records in the table.

5. For the table designed in question number 1 above, answer the following queries
using SQL:
(a) Display name and date_of_expiry of all the products whose price is more than
500.
(b) Display name, product ID and price of all the products whose
date_of_manufacture is after "01-01-2018".
(c) Display name and date_of_manufacture and date_of_expiry of all the products
whose price is between 5,000 and 10,000.
(d) Display name, product_ID and model of all the products which are going to
expire after two months froin today.
6. For the above database created in Q1, answer the following queries using SQL:
(a) Find all the parts supplied by supplier "123".
(b) Find the cities where supplier "324" is located.
(c) Find another supplier who supplies at least one part supplied by supplier "431".
(d) Find all the projects where part "P7" is used.
(e) Find all the suppliers who supplies part "P5".

INTERNAL EXAMINAR EXTERNAL EXAMINAR

You might also like