1. List the title from the titles table, the order number and order date from the...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
1. List the title from the titles table, the order number and order date from the sales table, and the store name from the stores table. Display only the first 30 characters of the title column. There should be a row produced in the result set for each row in the titles table. Order the result set by the order number. The query should produce the result set listed below. (Hint: LEFT OUTER JOIN statement) title Net Etiquette The Psychology of Computer Coo The Gourmet Microwave Straight Talk About Computers Bookshop Silicon Valley Gastronomic Tre Bookshop You Can Combat Computer Stress Bookshop (23 row(s) affected) ord_num stor_id stor_name P2121 P2121 ord_num TQ456 7896 423LL930 8042 P723 8042 NULL NULL 423LL922 (11 row(s) affected) Q02299 Fricative Bookshop Bookbeat Bookbeat TQ456 X999 7067 News & Brews 7067 News & Brews N914008 7131 Doc-U-Mat: Quality Laundry and Books ord_date NULL NULL 1994-09-14 00:00:00.000 1993-12-12 00:00:00.000 2. Using the INSERT command, add two books to the titles table. The first book has a title id of ZZ1234, title of Microsoft SQL Server, type of computer, publisher id of 0877, price of $89.99, and a publish date of September 29, 2008. The second book has a title id of TT2345, title of Designing Databases, type of computer, publisher id of 1389, priced of $168.98, and a publish date of January 1, 2009. 1993-10-28 00:00:00.000 Fricative 1993-02-21 00:00:00.000 3. List the sum of the order cost (quantity*price) for each order by store id, store name, order number, quantity, title, and price where the sum of the order cost is between $150.00 and $500.00. Display the order number, store id, and quantity from the sales table, the store name from the stores table, the price from the titles table, and the sum of the order cost. The query should produce the result set listed below. g|gzx_and 20 20 stor_name price NULL NULL Bookbeat 11.95 14.99 10.95 19.99 19.99 11.95 Fricative Fricative order_cost 239.00 299.80 219.00 199.90 199.90 298.75 4. Using the UPDATE command, increase the price by 10% for the book Microsoft SQL Server with a title id of ZZ1234. 5. Create a new table called BusinessBooks containing the title id, title, and price columns along with the data from the titles table which have a type of business. There should be 4 rows inserted into the new table. 1. List the title from the titles table, the order number and order date from the sales table, and the store name from the stores table. Display only the first 30 characters of the title column. There should be a row produced in the result set for each row in the titles table. Order the result set by the order number. The query should produce the result set listed below. (Hint: LEFT OUTER JOIN statement) title Net Etiquette The Psychology of Computer Coo The Gourmet Microwave Straight Talk About Computers Bookshop Silicon Valley Gastronomic Tre Bookshop You Can Combat Computer Stress Bookshop (23 row(s) affected) ord_num stor_id stor_name P2121 P2121 ord_num TQ456 7896 423LL930 8042 P723 8042 NULL NULL 423LL922 (11 row(s) affected) Q02299 Fricative Bookshop Bookbeat Bookbeat TQ456 X999 7067 News & Brews 7067 News & Brews N914008 7131 Doc-U-Mat: Quality Laundry and Books ord_date NULL NULL 1994-09-14 00:00:00.000 1993-12-12 00:00:00.000 2. Using the INSERT command, add two books to the titles table. The first book has a title id of ZZ1234, title of Microsoft SQL Server, type of computer, publisher id of 0877, price of $89.99, and a publish date of September 29, 2008. The second book has a title id of TT2345, title of Designing Databases, type of computer, publisher id of 1389, priced of $168.98, and a publish date of January 1, 2009. 1993-10-28 00:00:00.000 Fricative 1993-02-21 00:00:00.000 3. List the sum of the order cost (quantity*price) for each order by store id, store name, order number, quantity, title, and price where the sum of the order cost is between $150.00 and $500.00. Display the order number, store id, and quantity from the sales table, the store name from the stores table, the price from the titles table, and the sum of the order cost. The query should produce the result set listed below. g|gzx_and 20 20 stor_name price NULL NULL Bookbeat 11.95 14.99 10.95 19.99 19.99 11.95 Fricative Fricative order_cost 239.00 299.80 219.00 199.90 199.90 298.75 4. Using the UPDATE command, increase the price by 10% for the book Microsoft SQL Server with a title id of ZZ1234. 5. Create a new table called BusinessBooks containing the title id, title, and price columns along with the data from the titles table which have a type of business. There should be 4 rows inserted into the new table.
Expert Answer:
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date:
Students also viewed these databases questions
-
The Total Landed Costs (TLC) for a plastic wrap packaging machine from Germany to Monterrey, Mexico was calculated to be $723,566 USD. The company intends to use it for only 3 years and then resell...
-
Solve this linear programming (LP) problem using the transportation method. Find the optimal transportation plan and the minimum cost. Also, decide if there is an alternate solution. If there is one,...
-
After executing the following C code, what is displayed on the screen? Some lines of code have been removed for brevity. unsigned char i, j; float x, y; i= 'x'; j 95; x = 34.76f; y 24.024f;...
-
The bookkeeper of Beautiful World Landscaping, Inc., prepared the companys balance sheet while the accountant was ill. The balance sheet contains numerous errors. In particular, the bookkeeper knew...
-
Caldwell Company has 20,000 shares of common stock outstanding during all of 2007. It also has two convertible securities outstanding at the end of 2007. These are: 1. Convertible preferred stock:...
-
How do team learning processes, such as knowledge sharing, information processing, and feedback exchange, contribute to team innovation, adaptability, and sustained competitive advantage ?
-
Candy Craze purchased and installed a machine on January 1, 2023, at a total cost of $296,800. Straight-line depreciation was taken each year for four years, based on the assumption of a seven-year...
-
1. On March 1, Paige took advantage of low interest rates and refinanced her $75,000 home mortgage with her original lender. Paige purchased the home in 2018. The new home loan is for 15 years. She...
-
A cargo plane is moving with a horizontal velocity of 232 m/s and a height of 860 m above level ground when it releases a package ignoring air resistance. How much time in seconds will it take the...
-
OptiLux is considering Investing in an automated manufacturing system. The system requires an Initial Investment of $5.3 million, has a 20-year life, and will have zero salvage value. If the system...
-
Design and Evaluate Your Controller Performance Design one controller to form the closed-loop system, test its performance, and report the results in the following two tables II.I and II.2. The basic...
-
Find y'' for y = 2+ y" = 53 X
-
King Company estimated that it would operate its manufacturing facilities at 800,000 direct labour hours for the year, which served as the denominator activity in the predetermined overhead rate. The...
-
The expected return-beta relationship is the most familiar expression of the CAPM to practitioners. refers to the way in which the covariance between the returns on a stock and returns on the market...
-
Which of the ocean zones shown would be home to each of the following organisms: lobster, coral, mussel, porpoise, and dragonfish? For those organisms you identify as living in the pelagic...
-
Mike purchases a heavy-duty truck (5-year class recovery property) for his delivery service on April 30, 2012. The truck is not considered a passenger automobile for purposes of the listed property...
-
Mallory Corporation has a calendar year-end. The corporation has paid estimated payments of $10,000 during 2012 but still owes an additional $5,000 for its 2012 tax year. a. When is the 2012 tax...
-
Ulysses and Penelope are married and file separate returns for 2012. Penelope itemizes her deductions on her return. Ulysses' adjusted gross income was $17,400, his itemized deductions were $2,250,...
-
Define the correlation coefficient, \(ho_{X Y}\).
-
True or False. The autocorrelation function \(R\left(t_{1}, t_{2} ight)\) is the same as \(E\left[x\left(t_{1} ight) x\left(t_{2} ight) ight]\).
-
If \(x\) and \(y\) are statistically independent, then \(E[x y]=E[x] E[y]\). That is, the expected value of the product \(x y\) is equal to the product of the separate mean values. If \(z=x+y\),...
Study smarter with the SolutionInn App