How does query tree represent relational algebra expression, Database Management System

Assignment Help:

How does a query tree represent a relational algebra expression?  Discuss any three rules for query optimisation, giving example as to when should each rule be applied.   

 Ans: A query tree is a tree structure which refers to a relational algebra expression. It denotes the input relations as leaf nodes of the tree, and denotes the relational algebra operations as internal nodes. An execution of the query tree contains executing an internal node operation while its operands are available and after that replacing that internal node by the relation which results from executing the operation. The execution terminates while the root node is executed and generates the result relation for the query.  For instance, the query tree for the relational algebra expression

  ∏E_No =(σp_No = 'DB2003' (Assigned_To) :

The three rules for query optimization are like this:

  • In a cascade (sequence) of ∏ operations, each one but the last one can be ignored :

   ∏1(∏2(......∏n ( R))) ≡ ∏1(R )

  • If a selection condition c includes just only those attributes A1, A2, .... An in the projection list, the two operations can be commuted :

   ∏A1, A2,......An (σC (R ) ≡ σC  (∏A1, A2, ......An (R ))..... ))

  • A conjunctive selection condition can be split up into a cascade of individual σ operations:

  σC1 AND C2 AND ....AND  Cn  (R ) ≡ σC1C2(....(σCn (R ))....))


Related Discussions:- How does query tree represent relational algebra expression

Answer, what is database management system? & why it is required?

what is database management system? & why it is required?

What is database utility, What is database utility? Database utility is...

What is database utility? Database utility is the interface among the ABAP/4 Dictionary and the underlying the SAP system.

How many types of users works on database, How many types of users works on...

How many types of users works on database? Users are differentiated through the way they expect to interact along with the system (i) Application programmers-interact with

What is called block-level striping, What is called block-level striping? ...

What is called block-level striping? Block level striping stripes blocks across many disks. It treats the array of disks as a large disk, and provides blocks logical numbers

I need help on the following 5 questions, 1. Define and discuss Work Breakd...

1. Define and discuss Work Breakdown Structure, Critical Path Analysis, PERT charts and GANTT charts. Describe the role of each in determining scope, budgets, and schedules? What

List some instances of collection types, List some instances of collection ...

List some instances of collection types? a) sets b) arrays c) multisets

Information Technology, What benefits can a company gain by managing its ow...

What benefits can a company gain by managing its own information infrastructure and servicea

What is the concurrency identification, Concurrency Identification Whi...

Concurrency Identification While designing analysis, model we map real world model into our analytical model. Real life objects are simultaneous in nature, but all the design

Non-query optimisations, Part: Recommended (Non-query) Optimisations Thi...

Part: Recommended (Non-query) Optimisations This section entitled "Recommended (non-query) optimisations" should be a brief report containing recommended optimisations you would

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