Textbook ordering system, Database Management System

Assignment Help:

Question:

Consider the following database relations for a textbook ordering system used by a college bookshop:

Book (b-copy#, bname, ISBN#, author, price, subject)
Order (s#, b-copy#, order-date, payment)
Student (s#, sname, address, phone, course)

Assuming that:

?The attribute subject contained in the Book relation indicates the subject area a particular book belongs to. Examples of these subjects include 'programming', 'databases', 'operating systems', etc.

? The Student relation contains 1500 records;

? The Order relation contains 3500 records.

? The Book relation contains 4500 records. Each book copy has a unique number b-copy#. There are only 150 copies of "databases" books.

Provide the following:

(i) Express the following query in SQL:

"find all student names who have ordered any database book".

(ii) Choose two possible methods to evaluate the query, and use the relational algebra to formulate clearly all the steps required in the evaluation.

(iii) For each method, produce a query tree depicting all the steps.

(iv) For each method, calculate the number of tuples for all the intermediate relations (namely, size of the intermediate relations) required for each step.


Related Discussions:- Textbook ordering system

What is primary key explain, What is primary Key Explain? Primary Key ...

What is primary Key Explain? Primary Key - Primary key is one of the candidate keys. It should be selected such in which its attribute values are never, or very rarely, chang

Basic set operation, These are the binary operations; i.e., each is applied...

These are the binary operations; i.e., each is applied to two relations or sets. These two relations can be union compatible excluding in case of Cartesian product. Two relations R

Describe difference between a one-to-many and a many-to-many, Describe the ...

Describe the difference between a one-to-many and a many-to-many relationship. Which logical data structures comprise one-to-many and which comprise many-to-many relationship?

Relational algebra, Relational Algebra is a set of basic operations used to...

Relational Algebra is a set of basic operations used to influence the data in relational model. These operations allow the user to specify basic retrieval request. The result of re

Anomalies, define anomalies and different types of anomalies with example

define anomalies and different types of anomalies with example

What is dml (data manipulation language)?, This language that enable user m...

This language that enable user manipulate to or access data as organized by appropriate data model. Low level or Procedural DML : DML needs a user to specify what data ar

ER diagram, construct an er diagram for a hospital with a set of patients a...

construct an er diagram for a hospital with a set of patients and a set of medical doctors. associate with each patient a log of various test and examination conducted.convert er d

Differentiate between procedural and non procedural language, Differentiate...

Differentiate between Procedural and non procedural languages ? Procedural and non procedural languages - A procedural language specifies the operations to be performed on th

Write a query that uses the union operator, Write a Query that uses the UNI...

Write a Query that uses the UNION Operator 1. Use the Software Experts database to:   a. Display the first and the last name of all consultants who worked on any projects f

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd