• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 2 out of 14 pages
Exam (elaborations)

Introduction to Relational Databases Challenge 2.4 (WGU)

Document preview thumbnail
Preview 2 out of 14 pages

All invoices from USA will require a fee paid to an external organization for 10% of the total. Which of the following statements would query the sum of the total of the invoices in the country USA and calculate 10% of it?  a.)  SELECT AVG(total*.10) AS calculated_fee FROM invoice  WHERE billing_country = 'USA';  b.)  SELECT total(SUM)*.10 AS calculated_fee FROM invoice  WHERE billing_country = 'USA';  c.)  SELECT SUM(total)*.10 AS calculated_fee FROM invoice  WHERE billing_country = 'USA';  d.)  SELECT SUM(total)*.90 AS calculated_fee FROM invoice  WHERE billing_country = 'USA'; The organization would like to see how much money they would make if they increased the total by 20% for those who live in Canada. Which of the following statements would query the sum of the total of the invoices increased by 20% for those who live in Canada?  a.)  SELECT total*1.20 AS possible_total FROM invoice  WHERE billing_country = 'Canada';  b.)  SELECT SUM(total)*.20 AS possible_total FROM invoice  WHERE billing_country = 'Canada';  c.)  SELECT SUM(total)*1.20 AS possible_total FROM invoice  WHERE billing_country = 'Canada';  d.)  SELECT SUM(total)*.8 AS possible_total FROM invoice  WHERE billing_country = 'Canada'; Which of the following statements would query the invoice_line table to sum up the totals by multiplying the unit_price by the quantity grouped by invoice_id?  a.)  SELECT invoice_id, SUM(quantity * unit_price) AS total FROM invoice_line  ORDER BY total DESC;  b.)  SELECT invoice_id, quantity * unit_price AS total FROM invoice_line  GROUP BY invoice_id  ORDER BY total DESC;  c.)  SELECT invoice_id, SUM(quantity * unit_price) AS total FROM invoice_line  GROUP BY invoice_id  ORDER BY total DESC;  d.)  SELECT invoice_id, SUM(quantity + unit_price) AS total FROM invoice_line  GROUP BY invoice_id  ORDER BY total DESC; Which of the following is the valid syntax for creating a VIEW to view a subset of a table?  a.)  CREATE VIEW mississippi_customers SELECT * FROM customer WHERE state = 'MS';  b.)  CREATE VIEW mississippi_customers AS customer WHERE state = 'MS';  c.)  CREATE VIEW mississippi_customers AS customer SELECT *


Document information

Uploaded on
November 8, 2023
Number of pages
14
Written in
2023/2024
Type
Exam (elaborations)
Contains
Questions & answers
$19.99

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Oldspice
3.9
(209)
Sold
1214
Followers
867
Items
3786
Last sold
4 days ago



Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions

Whoops! We can’t load your doc right now. Try again or contact support.