1. Consider the Insurance database given below.

The primary keys are underlined and the

datatypes are specified. PERSON (driver – id #: Text, name: text, address: text) CAR (Regno: text, model: text, year: number) ACCIDENT (report-number: number, date: date, location: text) OWNS (driver-id #:text, Regno:text) PARTICIPATED (driver-id: text, Regno:text, report-number:number, damage amount:number) (i) Create the above tables by properly specifying the primary keys and the foreign keys. (ii) Enter atleast five tuples for each relation. (iii) Demonstrate how you a. Update the damage amount for the car with a specific Regno in the accident with report number 12 to 25000. b. Add a new accident to the database. (iv) Find the total number of people who owned cars that were involved in accidents in 2002. (v) Find the number of accidents in which cars belonging to a specific model were involved. (vi) Generation of suitable reports. (vii) Create suitable front end for querying and displaying the results. 2. Consider the following relations for an order processing database application in a company. CUSTOMER (cust #: number , cname: text, city: text) ORDER (order #: number, odate: date, cust #: number, ord-Amt: number) ORDER – ITEM (order #: number, Item #: number, qty: number) ITEM (item # : number, unit price: number) SHIPMENT (order #: number, warehouse#: number, ship-date: date) WAREHOUSE (warehouse #: number, city: text) (i) Create the above tables by properly specifying the primary keys and the foreign keys. (ii) Enter atleast five tuples for each relation. (iii) Produce a listing: CUSTNAME, #oforders, AVG_ORDER_AMT, where the middle column is the total numbers of orders by the customer and the last column is the average order amount for that customer. (iv) List the order# for orders that were shipped from all the warehouses that the company has in a specific city. (v) Demonstrate how you delete item# 10 from the ITEM table and make that field null in the ORDER_ITEM table. (vi) Generation of suitable reports. (vii) Create suitable front end for querying and displaying the results. 3. Consider the following database of student enrollment in courses & books adopted for each course. STUDENT (regno: text, name: text, major: text, bdate:date) COURSE (course #:number, cname:string, dept:string) ENROLL ( regno:string, course#:number, sem:number, marks:number) BOOK _ ADOPTION (course# :number, sem:number, book-ISBN:number) TEXT (book-ISBN:number, book-title:string, publisher:string, author:string)

branch-name:string. Book-title) in the alphabetical order for courses offered by the ‘CS’ department that use more than two books. branch-name:string. (vii) Create suitable front end for querying and displaying the results. customer-street:string. (iii) Give the details of the authors who have 2 or more books in the catalog and the price of the books is greater than the average price of the books in the catalog and the year of publication is after 2000. city:string. country:string) PUBLISHER (publisher-id:number. (vii) Create suitable front end for querying and displaying the results. year:number. city:string. (ii) Enter atleast five tuples for each relation. amount:real) BORROWER (customer-name : text. The following tables are maintained by a book dealer. country:string) CATALOG(book-id:number. title:string. name:string. Book-ISBN. 5. quantity:number) (i) Create the above tables by properly specifying the primary keys and the foreign keys.(i) Create the above tables by properly specifying the primary keys and the foreign keys. Consider the following database for a banking enterprise BRANCH (branch-name:string. publisher-id:number. name:string. (v) Demonstrate how you increase the price of books published by a specific publisher by 10% (vi) Generation of suitable reports. accno:number) CUSTOMER (customer-name:string. (iv) Find all the customers who have an account at all the branches located in a specific city. 4. (ii) Enter atleast five tuples for each relation. assets:real) ACCOUNT (accno:number. (vi) Generation of suitable reports. (iv) Find the author of the book which has maximum sales. (iv) Produce a list of text books (include Course #. AUTHOR (author-id:number. categoryid:number. (vii) Create suitable front end for querying and displaying the results. loan-number:number) (i) Create the above tables by properly specifying the primary keys and the foreign keys (ii) Enter atleast five tuples for each relation (iii) Find all the customers who have atleast two accounts at the Main branch. (v) List any department that has all its adopted books published by a specific publisher. description:string) ORDER-DETAILS (order-no:number. . (vi) Generation of suitable reports. balance:real) DEPOSITOR (customer-name:string. author-id:number. (v) Demonstrate how you delete all account tuples at every branch located in a specific city. (iii) Demonstrate how you add a new text book to the database and make this book be adopted by some department. price:number) CATEGORY (category-id:number. branch-city:string. book-id:number. customer-city:string) LOAN (loan-number:number.

phone. location. name. music. • A customer has to identify him/herself with driver’s license # (DLN). A rate ($ per day) has to be agreed on for each such renting event. (ii) Design suitable reports . at a specific time. Each garage is uniquely identified by its name. and credit card #. address. • A customer can rent a car by picking it up from one branch. at any time.Details such as name.Team details required to include team name and the days on which the team practices. (i)Identify and create the tables required for the DBMS project by properly specifying the primary keys and the foreign keys (ii) Enter atleast five tuples for each relation (iii) Design reports that a) List the customer(s) that bring the maximum business b) List the most frequently specified pickup point and the number of customers who use this pick up point. year. o Every member must belong to at least one team and each team has a number of members. Please required to carefully take care of the constraints on each of the table. Tutors teach at least one team and every team has at least one tutor. and color. The information about a garage includes name. 7. Design a DBMS solution to capture the requirements as stated below: A database is needed to capture information pertaining to the running of various clubs by the recreation cell of an institution. The system needs to know. . o Every team must belong to a club and clubs must have at least one team.6. A database is to be designed for a Car Rental Co. along with details of the skill each tutor is qualified in. dance.Club details are needed such as the activity type (oratorical. the car rental company requires that a customer provide multiples phone numbers. address and phone numbers. (vi) Create suitable queries that perform aggregation. Each has its own branch id. . • A car is described by its vehicle identification # (VIN). Usually. address and telephone number are also needed. o Every club has a member who is the president but a member may only be president of one club. • Each branch maintains a contract with a list of garages that provide a set of specific car maintenance services. instrumental music etc) and contact phone number. at which branch. . One customer can have at most one car at any given time. gender are needed for each member. where a car is – namely.Tutor details such as tutor name. model. • The car rental company has many branches. (iv) demonstrate how to delete a specific record (v) Create suitable front end for querying and displaying the results. The pick‐up location and drop‐off location don’t have to be the same. at a specific time and drop it off at another branch. (i) Create tables identified and insert five tuples in each of the tables created.Rules governing the involvement of members and tutors in the teams and clubs are as follows: o Members may head only one team and every team has to have a head. c) List the vehicle that is most used and least used. phone number and the manager’s name. date of birth. . make. .

Day) BOATS (Boatid. on deletion cascade Foreign Key: TRUCK_# REFERENCES TRUCK. WEIGHT. • List all the departments having an average salary of above Rs20. CUST_NAME. Cname. CUST_ID. (iv)Demonstrate the required queries as per the project guidelines. Major. 10. • List the names of all faculty members beginning with "R" and ending with letter "U". Consider the following relational database schema: STUDENT ( Student_id.SAILORS.000 ANNUAL_REVENUE defaults to $20. create a DBMS for the following schema CUSTOMER (CUST_ID. TRUCK_#. DRIVER_NAME) CITY (CITY_NAME. • Find the colors of boats reserved by "Ramesh" • Find the names of sailors who have reserved a red or green boat. grade) (i) Answer the following queries • List the names of all students enrolled for the courses "CS-53" • List the names of students enrolled for the courses "CS-53" and have received "A" grade. on deletion set to null Foreign Key: DESTINATION REFERENCES CITY. (ii) Design suitable reports (iii) Design suitable user interfaces. wholesaler. on deletion set to null WEIGHT must be under 1000 and defaults to 10 TRUCK (TRUCK_#. Student_id. fname. Consider the following three tables .(iii) Design suitable user interfaces. ANNUAL_REVENUE. DESTINATION. GPA) FACULTY (Faculty_id. • Give a 15% raise to salary of all faculty. 9. RESERVES and BOATS having the following attributes SAILORS (Salid.000. CUST_TYPE) CUST_ID must be between 100 and 10. Color) (i) Answer the following queries • Find the name of sailors who reserved green boat. POPULATION) Perform the following queries: a) What are the names of customers who have sent packages (shipments) to Sioux City? b) What are the names and populations of cities that have received shipments weighing over 100 pounds? . designation. Boatid. Rating. Faculty_id) ENROL (Course_id. Age) RESERVES (Salid. 8. Salname. salary) COURSE (Course_id. dept. • Find the Sailid's of sailors with age over 20 who have not registered a red boat. or retailer SHIPMENT (SHIPMENT_#.000 CUST_TYPE must be manufacturer. Sname. Boat-name. SHIP_DATE) Foreign Key: CUST_ID REFERENCES CUSTOMER. (ii) Design suitable reports (iii) Design suitable user interfaces.

the controlling department number. and within each department ordered alphabetically by employee last name.000 The other DBMS ideas are involving processes in the following areas • Hotel Management • Hospital administration • Inventory control • Manufacturing centre • Placement centre • Gas agency • Railway/Roadway/Airway reservation system • Academic administration • Sports databases . Customers with annual revenue between $1 million and $5 million. and what are the populations of those cities? 11. i) Find the names of the employees who work on all projects controlled by department number 2. which have received shipments from customers with revenue between $1 million and $5 million? iii. Which drivers have taken shipments to cities for customers with revenue under $1 million. e) answer the following queries: i. j) Retrieve all employees in department '3' whose salary is between 10.000 and 20. iii. address. What are the populations of cities. {using Exists and Nested query} e) Retrieve a list of employees and the projects each works in. and the name of his or her immediate supervisor. b) For each employee. f) Give all employees in the 'Research' department a 10% raise in salary. ii. and the department manager's last name. Customers with annual revenue under $1 million. Perform the following (any five) queries: a) For every project located in 'Stafford'. Which drivers have taken shipments to Los Angeles for customers with revenue over $5 million? ii.c) List the cities that have received shipments from customers having over $15 million in annual revenue. c) Make a list of all project numbers for projects that involve an employee whose last name is 'Smith' as a worker or as a manager of the department that controls the project. and birthdate. d) Retrieve the name of each employee who has a dependent with the same first name as the employee. retrieve the project number the project name and the number of employees who work on the project. g) For each project on which more than two employees work. Consider the schema for the COMPANY relational database design to support the follwong requirements. list the project number. h) Retrieve the Name and Address of all Employees who work for the 'Research' Dept. ordered by the employee's department. Customers with annual revenue over $5 million. retrieve the employee's name. d) Create reports for each of the following: i.

• Career opportunities • Employee database • Payroll system • Library management • Examination system management • Banking operations • Finance companies • Product Management • Pharmacy • Mall • News • Population • CET • College • Insurance • Movies • Manufacturing • Voting • Weather • Books • Websites • Travel • Real Estate • Wild life • Students • Income tax • Import-Export • Doctor • Railways .

Sign up to vote on this title
UsefulNot useful

Master Your Semester with Scribd & The New York Times

Special offer for students: Only $4.99/month.

Master Your Semester with a Special Offer from Scribd & The New York Times

Cancel anytime.