Answered step by step
Verified Expert Solution
Question
1 Approved Answer
You have been hired to develop a database system for an online ordering system. In this database, you want to store information about Restaurants, Clients,
You have been hired to develop a database system for an online ordering system. In this database, you want to store information about Restaurants, Clients, Orders, and Food. For each restaurant, you need to store the restaurant id, name, address, and type of food. For each client, you need to store client id, name, favorite restaurant, and credit card number. For each order, you need to store the order id, the client, the restaurant, and the food item being purchased. For each food, you need to store the food id, the type of food, the name of the food, and the number of calories in the dish. Assume that all ids are unique. Ensure your design allows the same client to make orders from the same restaurant on different days, even if the orders are identical in what type of food. Complete the following: 1. Create an ER diagram. [10 points] 2. List the primary keys, candidate keys, weak entities (if any), partial keys (if any), total participation, and any key constraints. [5 points] 3. Turn the ER diagram into tables (relational schema). Provide the SQL to create each table in the relational schema. [ 10 points]
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