Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1 - Suppose we have a database consisting of the following three relations SWIMMER(SSN, SNAME, LEVEL) BEACH(B#, BNAME, STATE, POLLUTION) SWIMMING(SSN. B#, DATE, DURATION) The

image text in transcribed
1 - Suppose we have a database consisting of the following three relations SWIMMER(SSN, SNAME, LEVEL) BEACH(B#, BNAME, STATE, POLLUTION) SWIMMING(SSN. B#, DATE, DURATION) The first relation (SWIMMER) indicates the swimmers and their level (beginner, intermediate, advanced), the second (BEACH) indicates different beaches across the country. Each beach has a number (B#) a name (BNAME) and a pollution rate of O (low pollution), 1 (moderate pollution), or 2 (high pollution). The third (SWIMMING) records the members swimming. (Relational Algebra symbols: (SIGMA), 7 (PROJECT). U (UNION), (INTERSECTION). (-) MINUS, M (JOIN) If you cannot copy-paste, simply type SIGMA, PROJECT, JOIN, etc.) N Express the following queries in (i) relational algebra and (1) SQL. 1. List the names of beaches that John Smith has visited? 2. List the names of swimmers who visited at least one beach to which John Smith has also been. 3. List the names of swimmers who visited only beaches to which John Smith has visited. 4. List the names of swimmers who visited no beach to which John Smith has been 5. List the names of the swimmers who visited all the beaches to which John Smith has been

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions