CS FundamentalsHardGATE CS · Product placement
R(A, B) = {(1, 4), (3, 4), (4, 1), (4, 3), (4, 4)} and S(B, C) = {(2, 5), (2, 7), (3, 5), (4, 6)}. How many tuples are in R ⟕ S (left outer join) and in R ⟗ S (full outer join)?
- A. 4 and 5
- B. 5 and 8
- C. 5 and 7
- D. 5 and 9
Correct answer: C. 5 and 7
R ⋈ S has 4 tuples; 1 R tuple(s) find no partner and are padded with NULL, giving 5. The full outer join also keeps 2 unmatched S tuple(s): 7.
More DBMS and SQL questions
- Entity sets Doctor, Patient and Drug participate in a single ternary relationship Prescribes with no cardinality constraints. Each entity…
- Table Staff(id, name, dept, pay, boss) rows: (1, 'Anu', 'Ops', 40, NULL), (2, 'Bala', 'Ops', 55, 1), (3, 'Chitra', 'Tech', 70, 1), (4…
- For the schedule W3(A), W3(C), R2(A), R1(A), W1(B), W4(A), R2(C), W4(B), how many serial schedules of T1–T4 are conflict-equivalent to it?
- R(A, B, C, D, E, F) has functional dependencies EF → D, A → C, BE → F, F → A, DF → A. What is the highest normal form R satisfies?
- Table Sale(id, rep, region, amt) rows: (1, 'Ira', 'N', 100), (2, 'Jai', 'S', 250), (3, 'Ira', 'S', NULL), (4, 'Kim', 'N', 300), (5, 'Jai'…
- Table Staff(id, name, dept, pay, boss) rows: (1, 'Anu', 'Ops', 40, NULL), (2, 'Bala', 'Ops', 55, 1), (3, 'Chitra', 'Tech', 70, 1), (4…