Best writers. Best papers. Let professionals take care of your academic papers

Order a similar paper and get 15% discount on your first order with us
Use the following coupon "FIRST15"
ORDER NOW

Need help this is due midnight and I have some issues with it!!

Need help this is due midnight and I have some issues with it!! The instructions and the sql information there as

well attached.  ATTACHMENT PREVIEW Download attachmentCIS336: Lab 6: Group Functions and SubqueriesLAB OVERVIEWScenario and SummaryLab 6 will introduce the concept of group funcTons and subqueries to meet more complex reportrequirements.±his lab may be completed using either DeVry’s Omnymbus EDUPE-APP lab environment,or a local copy of the MySQL database running on your own computer using the OM database tables.±he lab will uTlize a set of tables that are represented by the ERD (OM_ERD.docx) and are created andpopulated by the script Fle (create_OM_db.sql).²ollow the instrucTons in the FleCreateOMTables.docxto create your database, tables, and data.A few IMPORTANT things to note if using EDUPE MySQL:**±here can be NO SPACES in alias names given to a column.²or example:Select unit_price as “Retail Price “ from items;–this does NO± work in EDUPE MySQL.Any of the following WILL WORK:Select unit_price as “RetailPrice” from items;Select unit_price as “Retail_Price” from items;Select unit_price as Retail_Price from items;Select unit_price as RetailPrice from items;**Any calculated Felds MUS± be given an alias (and note above NO SPACES in alias).²or example:select unit_price * 2 from items;–this does NO± work in EDUPE MySQL±his will work:select unit_price * 2 as NewPrice from items;DeliverablesLab Report (Answer Sheet) containing both the student-created SQL command(s) for eachexercise, and the output showing the results obtained.Be sure your name is on the Fle.LAB STEPS:Complete each of the exercises below.CIS336 Lab 6 InstrucTonsPage 1

Background image of page 1

View the Answer1.Write a query to determine the total number of items on each order.Display the order_id and thetotal with a heading of TotalItems (note no spaces).Filter to only display informa±on for order_idof 600 or higher.2.Re-do query 1 but ²lter to only show those orders with more than 2 items ordered.Sort by thenumber of items ordered, lowest to highest.3.The order_details table has a quan±ty for each item ordered.Show the total amount charged foreach item on the order (quan±ty ±mes price).Display order_id, the item id, the unit price, thequan±ty ±mes price of the item labeled as “Itemtotal” (note NO spaces).Sort by order id and ²lterto only display those order ids between 400 and 700.4.Write a query to display the total amount for each order:show the order id and total.Sort bydescending order on the total and only display orders with a total of $40 or more.5.Re-do query 4 but show the customer name for each order (forma³ed as a single ²eld withheading of Customer) along with the city, order id and total.Filter to only display customers thatlive in California.Sort by city.6.Display the total amount of sales per item.Show ±tle, total quan±ty sold with a heading ofQuan±ty, total sales with a heading of “TotalSales” (not NO space).Sort by highest to lowest total.7.Display the total sales for each customer:show customer name (as single ²eld) with a heading ofCutomer and total.Sort lowest to highest total.Filter to only display customers with $50 or morein total orders.8.Use subqueries to determine which (ar±st) had the item ordered in highest quan±ty on an order?First determine the highest quan±ty on any order, then determine the item number associatedwith it, then display the ar±st.9.Display the total sales by ar±st:show ar±st name, total.Sort highest to lowest.10.USE A SUBQUERY to Increase price of all items by ‘No Rest for the Weary’ by 10%.If working inMySQl you will need to disable safe mode.Show prices before and a´er.Rollback a´er.CIS336 Lab 6 Instruc±onsPage 2

Background image of page 2

Show

 
Looking for a Similar Assignment? Order now and Get 10% Discount! Use Coupon Code "Newclient"