Week 3.pdf

Info icon This preview shows pages 1–10. Sign up to view the full content.

View Full Document Right Arrow Icon
EECS 116 & CS 122A Discussion - Week 3
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
THETA-JOIN A join that involves a predicate R1 | | q R2 = s q (R1 R2) Here q can be any condition using other operators such as <, >, <=, != .
Image of page 2
THETA-JOIN Output the names of all employees that earn more than their managers. Employee .Name ( Employee MngrId=Id AND Salary>Salary Manager ) The join yields a table with attributes: Employee. Name , Employee. Id , Employee. Salary , MngrId Manager. Name , Manager. Id , Manager. Salary
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
EXAMPLE
Image of page 4