Question: using AP database Please create solutions to the following queries: 1. Write a select statement that returns four columns based on the InvoiceTotal column of
using AP database

Please create solutions to the following queries: 1. Write a select statement that returns four columns based on the InvoiceTotal column of the invoices table, Cis11101 AP database. Use the CAST function to return the first column with O digits to the right of the decimal point Use the CAST function to return the second column with a $ in front of the value. Using the CONVERT function to return the third column with the smallest precision in mind to return the scale of 3. Use the CONVERT function to return the fourth column with a $ in front and back of the value. There should be no spaces between the symbols and number. i.e $3,813.33$ a. b. c. d. One row example without the headers: 3813$3813.33 3813.330 $3,813.335 Write a SELECT statement that returns two columns based on the Vendors table. The first column, Contact, is the vendor contact name, the second is the phone. 2. For the contact, the first name is followed by last name initial (for example, "John s.") The second column, Phone, is the VendorPhone column without the area code. a. b. Criteria: Only return rows for those vendors in the 559 area code. You can only use the numbers "559" in the search, no parenthesis Sort the result set by last name. 1) 2) One row example with headers: Contact Phone Thom A. 555-8484 Please create solutions to the following queries: 1. Write a select statement that returns four columns based on the InvoiceTotal column of the invoices table, Cis11101 AP database. Use the CAST function to return the first column with O digits to the right of the decimal point Use the CAST function to return the second column with a $ in front of the value. Using the CONVERT function to return the third column with the smallest precision in mind to return the scale of 3. Use the CONVERT function to return the fourth column with a $ in front and back of the value. There should be no spaces between the symbols and number. i.e $3,813.33$ a. b. c. d. One row example without the headers: 3813$3813.33 3813.330 $3,813.335 Write a SELECT statement that returns two columns based on the Vendors table. The first column, Contact, is the vendor contact name, the second is the phone. 2. For the contact, the first name is followed by last name initial (for example, "John s.") The second column, Phone, is the VendorPhone column without the area code. a. b. Criteria: Only return rows for those vendors in the 559 area code. You can only use the numbers "559" in the search, no parenthesis Sort the result set by last name. 1) 2) One row example with headers: Contact Phone Thom A. 555-8484
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
