Write the appropriate Microsoft SQL for the following with screen shots of the execution. i. Create food and supplierDetails tables as per the above given structure and insert the data to both the tables ii. Create a view that will display the food name and supplier name with supplier location which delivers the food. iii. Increase the prices of all food in the food table by 10% iv. Write a subquery to find names of supplier whose supplies ‘rice’.

Database Systems: Design, Implementation, & Management
12th Edition
ISBN:9781305627482
Author:Carlos Coronel, Steven Morris
Publisher:Carlos Coronel, Steven Morris
Chapter3: The Relational Database Model
Section: Chapter Questions
Problem 25P: Create the ERD. (Hint: Look at the table contents. You will discover that an AIRCRAFT can fly many...
icon
Related questions
Question

Write the appropriate Microsoft SQL for the following with screen shots of the execution.

i. Create food and supplierDetails tables as per the above given structure and insert the data to both the tables

ii. Create a view that will display the food name and supplier name with supplier location which delivers the food.

iii. Increase the prices of all food in the food table by 10%

iv. Write a subquery to find names of supplier whose supplies ‘rice’.

Table name: food
Column Name
Data Type
Constraint
foodID
Integer
Primary Key
foodName
Varchar
Not null
foodPrice
Number with three decimals
ExpiryDate
Date
SupplierID
Varchar
Foreign key
Table name: supplierDetails
Column Name
Data Type
Constraint
SupplicrID
SupplierName
varchar
Primary kcy
varchar
Not null
Location
varchar
Not null
Should be atleast 8 digits
PhoneNumber
Numeric
Transcribed Image Text:Table name: food Column Name Data Type Constraint foodID Integer Primary Key foodName Varchar Not null foodPrice Number with three decimals ExpiryDate Date SupplierID Varchar Foreign key Table name: supplierDetails Column Name Data Type Constraint SupplicrID SupplierName varchar Primary kcy varchar Not null Location varchar Not null Should be atleast 8 digits PhoneNumber Numeric
Expert Solution
steps

Step by step

Solved in 4 steps

Blurred answer
Knowledge Booster
SQL Query
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
  • SEE MORE 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
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781285196145
Author:
Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:
Cengage Learning
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning
Principles of Information Systems (MindTap Course…
Principles of Information Systems (MindTap Course…
Computer Science
ISBN:
9781285867168
Author:
Ralph Stair, George Reynolds
Publisher:
Cengage Learning
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
CMPTR
CMPTR
Computer Science
ISBN:
9781337681872
Author:
PINARD
Publisher:
Cengage