subject

Write the following queries in SQL based on the following schema:COP5725 - Spring 2011• Product(maker, model, type)• PC(model, speed, ram, hd, price)• Laptop(model, speed, ram, hd, screen, price)• Printer(model, color, type, price)a) Give the manufacturer and speed of laptops with a hard disk of at least 30 gigabytesSELECT R. maker AS manufacturer, L.speed AS gigahertzFROM Product R, Laptop LWHERE L. hd>= 30AND R. model = L. modelAND R. type= ‘laptop’;b) Find the model number and price of all products (of any type) made by manufacturer 'B'SELECT R. model, P. price FROM Product R, PC PWHERE R. maker= 'B‘ AND R. model = P. modelUNIONSELECT R. model, L. price, FROM Product R, Laptop LWHERE R. maker= 'B‘ AND R. model = L. modelUNIONSELECT R. model, T. price FROM Product R, Printer TWHERE R. maker= 'B’ AND R. model = T. model ;c) Find those manufacturers that sell Laptops, but no PC'sSELECT R. makerFROM Product R, Laptop LWHERE R. model = L. model and R. Type= ‘Laptop’EXCEPTSELECT R. makerFROM Product R, PC PWHERE R. model = P. model and R. Type= ‘PC’ ;d) Find those hard-disk sizes that occur in two or more PC'sSELECT DISTINCT P1.hdFROM PC P1, PC P2WHERE P1.hd = P2.hd AND P1.model > P2.model ;Alternate SELECT DISTINCT P. hdFROM PC PGROUP BY P. hdHAVING COUNT(*) >= 2 ;

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 18:30
Ayear in the modern gregorian calendar consists of 365 days. in reality, the earth takes longer to rotate around the sun. to account for the difference in time, every 4 years, a leap year takes place. a leap year is when a year has 366 days: an extra day, february 29th. the requirements for a given year to be a leap year are: the year must be divisible by 4if the year is a century year (1700, 1800, the year must be evenly divisible by 400some example leap years are 1600, 1712, and 2016.write a program that takes in a year and determines whether that year is a leap year.ex: if the input is 1712, the output is: 1712 is a leap year.ex: if the input is 1913, the output is: 1913 is not a leap year.
Answers: 2
question
Computers and Technology, 23.06.2019 16:00
Helen is having a meeting with her colleagues in her company. they are working on the goals and objectives for the coming year. they want to ensure that these goals and objectives of the processes involved are properly evaluated. which system can helen and her colleagues apply to evaluate this? helen and her colleagues require a blank to evaluate the goals and objectives.
Answers: 2
question
Computers and Technology, 24.06.2019 00:00
Visualizing a game of “tag” to remember the meaning of contagious
Answers: 3
question
Computers and Technology, 24.06.2019 10:00
(, urgent need): how do i change my username
Answers: 1
You know the right answer?
Write the following queries in SQL based on the following schema:COP5725 - Spring 2011• Product(make...
Questions
question
Mathematics, 05.12.2020 02:30
question
Mathematics, 05.12.2020 02:30
question
Mathematics, 05.12.2020 02:30
question
English, 05.12.2020 02:30
question
Biology, 05.12.2020 02:30
question
Mathematics, 05.12.2020 02:30
question
Social Studies, 05.12.2020 02:30
question
English, 05.12.2020 02:30
question
Geography, 05.12.2020 02:30
question
Mathematics, 05.12.2020 02:30
Questions on the website: 13722367