Consider the database described in http://www.cs.helsinki.fi/u/laine/tkpv/pizza2sql.html.
and the following query
select i.orderid, i.productid, pn.objectname, p.modelid,
p.price, i.amount
from itemordered i, product p, objectname pn
where p.productid=i.productid and
i.modelid=p.modelid and
i.orderid=3019 and pn.language='english' and
pn.objectid=i.productid
- Construct a tree representation of this query (determine the
operations of relational algebra and their sequence, the tree need not be optimized)
- Estimate the sizes of the intermediate and final results.We know that
table itemordered has 100000 rows. There are 25000 orders. Table product has 100 rows and table objectname has
600 rows that specify the names in 3 languages.