Question
QUESTION 5 Answer all parts The following is the description of a database table for a property for rent Property(propertyNumber, Property_Name, Address, No_of_rooms, Rent_per_month, Property_Type)
QUESTION 5 Answer all parts The following is the description of a database table for a property for rent Property(propertyNumber, Property_Name, Address, No_of_rooms, Rent_per_month, Property_Type) (a) Write an SQL UPDATE statement to update the rent in all properties by 100 which has a property type of detached. (4 marks) (b) Write an SQL UPDATE statement to update the number of rooms for the property number 10 to have 8 rooms (i.e. as if it has been renovated to include two more rooms). (4 marks) (c) Write an SQL DELETE statement which deletes all records from the Property table which have less than four rooms. (4 marks) (d) Write statements to create the table from relational schema described above. Select appropriate data types for each attribute. Remember to set the primary key. (8 marks) (e) Write a SQL statement to select all the properties that are located in Cork.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started