# Question

Consider the relational database of Figure. Give a relational-algebra expression for each of the following queries:

a. Find the company with the most employees.

b. Find the company with the smallest payroll.

c. Find those companies whose employees earn a higher salary, on average, than the average salary at First BankCorporation.

a. Find the company with the most employees.

b. Find the company with the smallest payroll.

c. Find those companies whose employees earn a higher salary, on average, than the average salary at First BankCorporation.

## Answer to relevant Questions

List two reasons why we may choose to define a view.Let R = (A, B) and S = (A, C), and let r(R) and s(S) be relations. Write relational-algebra expressions equivalent to the following domain-relationalcalculus expressions: a. {< a > | ∃ b (< a, b >∈ r ∧ b = ...Let the following relation schemas be given: R = (A, B, C) S = (D, E, F) Let relations r(R) and s(S) be given. Give an expression in SQL that is equivalent to each of the following queries. a. п A(r) b. σB = ...SQL-92 provides an n-ary operation called coalesce, which is defined as follows: coalesce (A1,A2, . . . , An) returns the first nonnull Ai in the list A1,A2, . . .,An, and returns null if all of A1,A2, . . .,An are null. ...Let the following relation schemas be given: R = (A, B, C) S = (D, E, F) Let relations r(R) ands(S) be given. Give expressions in QBE, and Data log equivalent to each of the following queries: a. IIA(r) b. σB =17 ...Post your question

0