Question: Write an SQL script that builds a database to match the relational model provided. These SQL statements in the script must be provided in the
Write an SQL script that builds a database to match the relational model provided. These SQL statements in the script must be provided in the correct order.

OKTOMOOK relational model Customers (customerNumber, firstName, lastName, Address, city, State, postcode, region, email) Books (ISBN, title, pubDate, PublD, Cost, Retail, Discount, category) Orders (orderNumber, customerNumber, orderDate, shipDate, street, city, state, postCode, shipCost) Ordersltems (orderNumber, itemNumber, ISBN, quantity, paidEach) Author (authorlD, firstName, lastName) Wrote ISBN, authorlD) Publishers (publd, name, contact, phone) FOREIGN KEYS Orders (customerNumber) is dependent on Customers(customerNumber) Orders (orderNumber) is dependent on Ordersltems(orderNumber) Wrote (authorlD) is dependent on Author (authorlD) Wrote(ISBN) is dependent on Books(ISBN) Books(publD) is dependent on Publishers(publD) OTHER CONSTRAINTS The domain of customer(state) and orders(shipState) are [QLD, VIC, NSW, WA, TAS, NT, SA] ISBN must be a 13-digit number and may begin with a zero The publisher name and book title are both mandatory The default Orderltems(quantity) is 1 The Book(category) are Fitness, Children, Computer, Cooking, Business, Literature
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
