subject

Consider the following schema: suppliers (sid: integer, sname: string, street: string, city: string, zip: string) parts (pid: integer, pname: string, color: string) catalog (sid: integer, pid: integer, cost: real)the primary key attributes are underlined, and the domain of each attribute is listed after the attribute name. thus, sid is the primary key for suppliers, pid is the primary key for parts, and sid and pid together form the primary key for catalog. attribute sid in catalog is a foreign key that refers to the primary key sid of suppliers and pid in catalog is a foreign key that refers to the primary key pid of parts. the catalog relation lists the prices charged for parts by suppliers. state what the following query computes.0. πcity (πpid (σ color = 'green' (parts) ) * σ cost> 50 (catalog) * πsid, city (suppliers) )write the following queries in relational algebra.1. find the names of parts for which there is some supplier2. find the names of parts supplied by suppliers who are at 1 central ave.3. find the names of suppliers who supply some red part.4. find the sids of suppliers who supply some red or green part.5. find the sid of suppliers who supply some red part or whose address is '221 packer street'.6. find the sids of suppliers who supply some red part and some green part.7. find the pids of parts that are red or are supplied by a supplier who is at the city of newark.8. find the pids of parts supplied by a supplier who is at the city of newark and by a supplier who is at the city of trenton.9. find the pids of parts supplied by every supplier.10. find the pids of parts supplied by every supplier who supplies at least one part.11. find the sids of suppliers who supply at least two different parts (you are not allowed to use a grouping/aggregation operation for this query).12. find the sids of suppliers who supply at least two different parts (you have to use a grouping/aggregation operation for this query).13. for every part, find its pid, its pname and the number of suppliers who sell it.14. list the pid, pname and average cost of all parts.15. find the average cost of red parts.16. find the average cost of parts supplied by suppliers named 'yosemite sham'.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 08:00
What best describes a career pathway in a lodging career? a worker starts out as an amusement attendant, then becomes a recreation worker, and then becomes a gaming worker within five years. a worker starts out as a bell hop, then becomes a night clerk, and then becomes a hotel manager within five years. a worker starting out as a tour guide, then becomes a travel clerk, and then becomes a travel agent within five years. a worker starts out as a server, then becomes a food preparer, and then becomes a head chef within five years.
Answers: 1
question
Computers and Technology, 24.06.2019 13:30
What is the most important for you to choose before you build a network?
Answers: 1
question
Computers and Technology, 24.06.2019 22:50
Which of these might be an example of an advertiser's target group? a.people who have no access to media b.people the advertisers know nothing about c. people who watch a variety of tv shows d. people who live in the same region of the country
Answers: 2
question
Computers and Technology, 25.06.2019 01:30
Why is the most liked picture on instagram an eggy? owo
Answers: 1
You know the right answer?
Consider the following schema: suppliers (sid: integer, sname: string, street: string, city: str...
Questions
question
Spanish, 01.05.2021 07:20
question
Mathematics, 01.05.2021 07:20
question
English, 01.05.2021 07:20
question
Arts, 01.05.2021 07:20
question
Mathematics, 01.05.2021 07:20
Questions on the website: 13722363