Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

DreamHome wants to add the capacity to store information about Auctions to its database. This will include functionality to store properties for sale ( as

DreamHome wants to add the capacity to store information about Auctions to its database. This will include functionality to store properties for sale (as opposed to for rent), store details about when an auction happens, and what houses were sold at that auction. A consultant has been commissioned to model these business requirements, and has produced the following RMap: Figure 1, RMap: - PropertyForSale (propertyNo, address, postcode, propertyType, rooms, listingPrice, ownerNo, staffNo, branchNo); - Auction (auctionNo, date, auctionAddress, branchNo); - AuctionedProperty (auctionNo, propertyo, finalBidAmount, soldFor); The consultant included some notes about constraints: Figure 2, Constraints Constraints: - listingPrice must be greater than $500000.00.- auctionAddress can be NULL, this means it is at the property for sale address. - soldFor is $500000.00 by default. - finalBidAmount can be NULL, this means the soldFor price is the same as the finalBidAmount. - In the 'PropertyForSale' table: ownerNo, staffNo and branchNo reference the attributes of the same name in the PropertyOwner, Staff and Branch table respectively. - In the 'Auction' table: branchNo references the attribute of the same name in the Branch - In the 'AuctionedProperty' table: auctionNo and propertyNo references the attributes of the same name in the Auction and PropertyForSale tables respectively. Some sample tables have been included to help determine datatypes Figure 3, Data: PropertyForSale Figure 3, Data: PropertyForSale Auction AuctionedProperties Your task is to create a SQL script (DreamHome_23s2_Auctions.sql) that will execute to create these tables in a MySQL database. Be sure to include: all tables and their attributes, primary keys, foreign keys, any constraints. Your script should be able to be executed in one run without errors.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database Upgrade Migration And Transformation Tips And Techniques

Authors: Edward Whalen ,Jim Czuprynski

1st Edition

0071846050, 978-0071846059

More Books

Students also viewed these Databases questions

Question

5. Have you stressed the topics relevance to your audience?

Answered: 1 week ago