Concept explainers
I need this answer in SQL. . SQL please if your going to answer it
Populate fields into your tables. Create original and expected items for each field. Do not use generic fillers.
Side: 7 rows
Entree: 5 rows
Menu: 4 rows (seasonal)
Zip: 4 rows (local)
Address: 10 rows
Menu_Dish: 5 rows
Side_List: 8 rows (matching menu dishes with sides)
Dish_Build: 16 rows (matching menu with menu dishes)
Event_Menu: 4 rows
Member: 12 rows
- Add rows of inserts that simulates the invitation process. Write the insert statements for 100% invitations for one event.
- Then, add rows of inserts that simulate the return of only 10 RSVPs. You can decide which 10 people RSVP.
- Of those 10 RSVPs, two are not attending.
- Of those attending, 50% will have guests.
- Also, write the inserts for those attending and their dish selection.
Finally, complete this query at the bottom of your
Write a SQL statement that gives you all the names of the people that attended one of your seasonal events and specify if they are members or guests. (Without using the wildcard (*) for the fields.)
Trending nowThis is a popular solution!
Step by stepSolved in 2 steps with 2 images
- database: sql Q1. Create the following tables: Carrier Attribute name Type Size Constraint carrierID Varchar2 10 Primary key carrierName Varchar2 100 NOT NULL Phone Varchar2 50 LIKE ‘+966%’ Range Varchar2 30 Value is either ‘International’ or ‘Local’ Review Attribute name Type Size Constraint ReviewID INT Primary key Stars INT NOT NULL Comment Varchar2 70 Name Varchar2 50 Default ’User’ CustomerID INT Foreign key references customers ProductID INTarrow_forwardPLZ help with the following using ORACLE command sql Use subqueries CREATE TABLE MEMBERSHIP ( MEM_NUM CHAR(3) CONSTRAINT MEMBER_MEM_NUM_PK PRIMARY KEY, MEM_FNAME VARCHAR(30) NOT NULL, MEM_LNAME VARCHAR(30) NOT NULL, MEM_STREET VARCHAR(15), MEM_CITY VARCHAR(10), MEM_STATE CHAR(2), MEM_ZIP CHAR(5), MEM_BALANCE NUMBER (2)); CREATE TABLE RENTAL ( RENT_NUM CHAR(4) CONSTRAINT RENTAL_RENT_NUM_PK PRIMARY KEY, RENT_DATE DATE, MEM_NUM CHAR(3), CONSTRAINT RENTAL_MEM_NUM_FK FOREIGN KEY (MEM_NUM) REFERENCES MEMBERSHIP); CREATE TABLE PRICE (PRICE_CODE CHAR(1) CONSTRAINT PRICE_PRICE_CODE_PK PRIMARY KEY, PRICE_DESC VARCHAR(20), PRICE_RENTFEE NUMBER (3,1), PRICE_DAILYATFEE NUMBER(3,1)); CREATE TABLE MOVIE (MOVIE_NUM CHAR(4) CONSTRAINT MOVIE_MOVIE_NUM_PK PRIMARY KEY, MOVIE_NAME VARCHAR(30) NOT NULL, MOVIE_YEAR CHAR(4), MOVIE_COST NUMBER(5,2), MOVIE_GENRE VARCHAR(15), PRICE_CODE CHAR(1), CONSTRAINT MOVIE_PRICE_CODE_FK FOREIGN KEY (PRICE_CODE) REFERENCES PRICE); CREATE TABLE VIDEO…arrow_forwardWrite a SQL query to find the customer# of those customers that purchased at least once in July 2020 but NOT in August 2020. In addition to the customer#, show the ISBN and title of the book(s) they purchased in July 2020. You may use only one query. No creating any temporary tables or subqueries. You may use only joins. SUBMIT a second solution in addition to your Level 1.arrow_forward
- I want to write the SQL to create the tables for the ERD attached, but I also want to add this to the tables: rental date, due date, and return date so that I can support overdue queries. I also want it so each table has primary keys and foreign keys. I want it so the tables have at least 4 rows of data. How can I do this? Thank you for your help as I learn more about SQL and table creation.arrow_forwardTask 3: The InstantRide Finance team wants to collect the price and discount information with the driver names for each travel in the system. You need to return the TRAVEL_ID, DRIVER_FIRST_NAME, DRIVER_LAST_NAME, TRAVEL_PRICE, and TRAVEL_DISCOUNT information from the TRAVELS and DRIVERS tables combined over DRIVER_ID field with the ON keyword. Task: Calculate each user's price and discount information. (SQL Database Test)arrow_forwardSQL Code for Extend the code in (Perform a LEFT OUTER JOIN between the tables Wicketkeeping and Batting. You may select any column(s). Look at the result and state how many wicketkeepers have not played as batsmen (no need to write code for this part ) To show the name of the fielders who have played 7 times as many matches as the wicketkeeper(s) in 5).arrow_forward
- help with sql class Report the names of the professors who work on the most number of projectsarrow_forwardGo to the w3schools website’s SQL browser IDE. This is where you canwrite and test your SQL code using their databases. Once you are happywith it, paste your code in a text file named Student.txt and save it in yourtask folder.● Write the SQL code to create a table called Student. The table structure issummarised in the table below (Note that STU_NUM is the primary key):Attribute Name Data TypeSTU_NUM CHAR(6)STU_SNAME VARCHAR(15)STU_FNAME VARCHAR(15)STU_INITIAL CHAR(1)STU_STARTDATE DATECOURSE_CODE CHAR(3)PROJ_NUM INT(2)● After you have created the table in question 1, write the SQL code to enterthe first two rows of the table as below:STU_NUMSTU_SNAMESTU_FNAMESTU_INITIALSTU_STARTDATECOURSE_CODEPROJ_NUM01 Snow John E 05-Apr-14 201 602 Stark Arya C 12-Jul-17 305 11● Assuming all the data in the Student table has been entered as shownbelow, write the SQL code that will list all attributes for a COURSE_CODE of305.…arrow_forwardCreate a Pl SQL package named EMP_PKG which will have the above three functions and procedures as follows: CALC_TAX - private CHECK_FNAME - Public AVG_SAL - Publicarrow_forward
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education