Using the tables below Now create a query, which will show the equipment rented out with status. You should include all columns relevant to this query context. (You have to decide).   CREATE TABLE equipment{ equipmentId int, equipmentDesc varchar(50), equipmentPrice decimal(8,2), Primary key(equipmentId, equipmentPrice) ); CREATE TABLE rental( Rentalid int, RentalDate date, equipmentId int, equipmentPrice decimal(8,2), Status char(1) Primary key(Rentalid, RentalDate), Foreign key(equipmentId, equipmentPrice) references equipment(equipmentID, equipmentPrice) );

Database Systems: Design, Implementation, & Management
12th Edition
ISBN:9781305627482
Author:Carlos Coronel, Steven Morris
Publisher:Carlos Coronel, Steven Morris
Chapter8: Advanced Sql
Section: Chapter Questions
Problem 52P
icon
Related questions
Question

Using the tables below

Now create a query, which will show the equipment rented out with status. You should include all columns relevant to this query context. (You have to decide).

 

CREATE TABLE equipment{
equipmentId int,
equipmentDesc varchar(50),
equipmentPrice decimal(8,2),
Primary key(equipmentId, equipmentPrice)
);

CREATE TABLE rental(
Rentalid int,
RentalDate date,
equipmentId int,
equipmentPrice decimal(8,2),
Status char(1)
Primary key(Rentalid, RentalDate),
Foreign key(equipmentId, equipmentPrice) references equipment(equipmentID, equipmentPrice)
); 

Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Single Table
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781305627482
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
A Guide to SQL
A Guide to SQL
Computer Science
ISBN:
9781111527273
Author:
Philip J. Pratt
Publisher:
Course Technology Ptr
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage