Using the ERD you created in Task 1, develop a create.sql file that will create a...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Using the ERD you created in Task 1, develop a create.sql file that will create a database named grubhub. Using the grubhub database, include statements in your file to create all the entities, attributes and primary and foreign key constraints detailed in your ERD. O Make sure to end each statement with a semicolon (;) O The creation scripts we have used in class are a great guide! Test running your create.sql file in our development environment. Adjust your script as needed. PK, FK Restaurants number, payment ID, address, name, phone number, and cuisine PK, FK PK, FK Orders unique number timestamp PK, FK GrubHub payment IDs PK, FK PK, FK Drivers status (paced, out, cancelled, and fullfilled) name, phone number, license plate number, drivers license number, payment ID, and status (active/inactive) PK, FK Customers number, name adress name, phone number, and payment ID record Name 1 April Ludgate 2 April Ludgate 3 Leslie Knope 4 Ron Swanson 5 Andy Dwyer 6 Task 3: Add Sample Data (15 pts) 6. Add insert statements to your create.sql file to add the data pictured below. This data is present in tables at the end of this document. Address 1235 55 Ave, Omaha, NE 68132 1235 55 Ave, Omaha, NE 68132 4387 Waffles Drive, Pawnee, IN, 46011 987 Bacon Avenue, Pawnee, IN 46011 2468 The Pit, Pawnee, IN 46011 Phone 402-553-4397 402-553-4397 234-432-5437 456-987-3265 pmt_id restaurant name address 23456 Paunch Burger 23456 Paunch Burger 98754 JJ's Diner 234789 Mulligan's 12390 JJ's Diner 6872 Lard Lane, Pawnee, IN 46011 6872 Lard Lane, Pawnee, IN 46011 23428 Main St. Pawnee, IN 46011 6876 Classy Rd., Indianapolis, IN 46077 23428 Main St. Pawnee, IN 46011 phone cuisine 678-893-1568 Fast food 678-893-1568 Fast food 456-987-3185 Breakfast 786-235-4862 Steakhouse 456-987-3185 Breakfast O rest. Pmt_id driver 4826 Henry Roth 4826 Charity Osborne 78623 Fritz Macias 48623 Brenden Hill 78623 Henry Roth Leah Peters phone license plate drivers license drv. Pmt_id drv. Status order date (286) 937-2250 IUC989 C04790049 444862 active (815) 605-0336 REW222 D89973937 959227 active (943) 893-6193 XUA177 U06119817 718371 active (513) 284-9064 IOL455 X22173227 334452 active (286) 937-2250 IUC 989 C04790049 444862 active (909) 477-8843 AJA879 V44276914 603268 inactive order status 9/30/2020 6:44 out 9/30/2020 10:44 placed 9/30/2020 10:54 fulfilled 9/30/2020 10:46 placed 9/30/2020 11:44 cancelled 7. Test running your create.sql file in our development environment. Adjust your script as needed. Using the ERD you created in Task 1, develop a create.sql file that will create a database named grubhub. Using the grubhub database, include statements in your file to create all the entities, attributes and primary and foreign key constraints detailed in your ERD. O Make sure to end each statement with a semicolon (;) O The creation scripts we have used in class are a great guide! Test running your create.sql file in our development environment. Adjust your script as needed. PK, FK Restaurants number, payment ID, address, name, phone number, and cuisine PK, FK PK, FK Orders unique number timestamp PK, FK GrubHub payment IDs PK, FK PK, FK Drivers status (paced, out, cancelled, and fullfilled) name, phone number, license plate number, drivers license number, payment ID, and status (active/inactive) PK, FK Customers number, name adress name, phone number, and payment ID record Name 1 April Ludgate 2 April Ludgate 3 Leslie Knope 4 Ron Swanson 5 Andy Dwyer 6 Task 3: Add Sample Data (15 pts) 6. Add insert statements to your create.sql file to add the data pictured below. This data is present in tables at the end of this document. Address 1235 55 Ave, Omaha, NE 68132 1235 55 Ave, Omaha, NE 68132 4387 Waffles Drive, Pawnee, IN, 46011 987 Bacon Avenue, Pawnee, IN 46011 2468 The Pit, Pawnee, IN 46011 Phone 402-553-4397 402-553-4397 234-432-5437 456-987-3265 pmt_id restaurant name address 23456 Paunch Burger 23456 Paunch Burger 98754 JJ's Diner 234789 Mulligan's 12390 JJ's Diner 6872 Lard Lane, Pawnee, IN 46011 6872 Lard Lane, Pawnee, IN 46011 23428 Main St. Pawnee, IN 46011 6876 Classy Rd., Indianapolis, IN 46077 23428 Main St. Pawnee, IN 46011 phone cuisine 678-893-1568 Fast food 678-893-1568 Fast food 456-987-3185 Breakfast 786-235-4862 Steakhouse 456-987-3185 Breakfast O rest. Pmt_id driver 4826 Henry Roth 4826 Charity Osborne 78623 Fritz Macias 48623 Brenden Hill 78623 Henry Roth Leah Peters phone license plate drivers license drv. Pmt_id drv. Status order date (286) 937-2250 IUC989 C04790049 444862 active (815) 605-0336 REW222 D89973937 959227 active (943) 893-6193 XUA177 U06119817 718371 active (513) 284-9064 IOL455 X22173227 334452 active (286) 937-2250 IUC 989 C04790049 444862 active (909) 477-8843 AJA879 V44276914 603268 inactive order status 9/30/2020 6:44 out 9/30/2020 10:44 placed 9/30/2020 10:54 fulfilled 9/30/2020 10:46 placed 9/30/2020 11:44 cancelled 7. Test running your create.sql file in our development environment. Adjust your script as needed.
Expert Answer:
Related Book For
Modern Database Management
ISBN: 978-0133544619
12th edition
Authors: Jeff Hoffer, Ramesh Venkataraman, Heikki Topi
Posted Date:
Students also viewed these algorithms questions
-
List three specific parts of the Case Guide, Objectives and Strategy Section (See below) that you had the most difficulty understanding. Describe your current understanding of these parts. Provide...
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
The table represents values of differentiable functions f and g and their first derivatives. Use the table of values to answer the questions that follow. Work all of the parts below the line. X f g...
-
What marketing risks are taken by outsourcing? How would you minimize those risks?
-
Consider the following table of constraint coefficients for a linear programming problem. Show how this table can be converted into the form for multidivisional multitime period problems shown in...
-
Given the following set of periodic processes running on a single CPU (P1 has highest priority), what is the maximum execution time x of P3 for which all the processes will be schedulable using EDF?...
-
John Wiggins is contemplating the purchase of a small restaurant. The purchase price listed by the seller is $800,000. John has used past financial information to estimate that the net cash flows...
-
a. The owner invested $17,800 cash in the company. b. The company purchased supplies for $1,200 cash. c. The owner invested $11,400 of equipment in the company in exchange for more common stock. d....
-
From the adjustments columns in Exercise 5-9A, journalize the four adjusting entries, as of December 31, in proper general journal format. Exercise 5-9A Jim Jacobs Furniture Repair Work Sheet...
-
Rainbow Company's income statement and comparative balance sheets follow. RAINBOW COMPANY Income Statement For Year Ended December 31, 2016 Sales $1,125,000 Dividend Income 22,500 Total Revenue...
-
When an asset is sold, the undepreciated capital cost in its asset class (or pool) is reduced by what is realized on the asset or by its original cost, whichever is less. This amount is called the?
-
Entered a 6 year loan on 1 march current year for the purchase of equipment that was required for income producing purpose. The borrowing cost assosiated with loan were. 750. What is deductible...
-
A 3.00-kg ball, moving to the right at a velocity of +3.50 m/s on a frictionless table, collides head-on with a stationary 7.90-kg ball. Find the final velocities of (a) the 3.00-kg ball and of (b)...
-
Which alternative is better? probability of soft kill of each three alternatives against each of three threats. in addition, the relative frequency of attacks is 40% by country 1, 50% by country 2,...
-
How do protein conformational changes, such as allosteric transitions, modulate enzymatic activity and cellular signaling cascades?
-
Q5:Represnet this equation in Matlap Simulink and determine the record the output written in the display screen: 11 y=-0.4 + eT * log(2)
-
The process of collaborative goal setting by a manager and subordinate, the extent to which goals are accomplished is a major factor in evaluating and rewarding the subordinate's performance. It is...
-
List and briefly explain how integrity controls can be used for database security.
-
Show the customer ID and name for all the customers who have ordered both products with IDs 3 and 4 on the same order.
-
Explain the reasons why some experts are against the practice of denormalization.
-
The relativity of simultaneity. Two clocks are placed at rest on the \(x^{\prime}\) axis of the primed frame, clock A at \(x^{\prime}=0\) and clock B at \(x^{\prime}=L_{0}\). They are therefore a...
-
A primed frame moves at \(V=(3 / 5) c\) relative to an unprimed frame. Just as their origins pass, clocks at the origins of both frames read zero, and a flashbulb explodes at that point. Later, the...
-
Two spaceships are approaching one another. According to observers in our frame, (a) the left-hand ship moves to the right at \((4 / 5) c\) and the right-hand ship moves to the left at \((3 / 5) c\)....
Study smarter with the SolutionInn App