Question: Please use SQL Developer to write the queries below. Copy and paste your query code into the submission box for this assignment. This assignment should
Please use SQL Developer to write the queries below. Copy and paste your query code into the submission box for this assignment. This assignment should be completed by July 16th.
Write a query that displays the customer lastname, and address as Customer Address from customers. Use a function to replace the string P.O. with Post Office".
Write a query that shows the first and last name of each customer as well as their city and state, and whether or not the customer was referred by another customer. If they were referred, display "Referred," and if not, display "Not Referred." Customer names should be lower case with the first letter capitalized.
Write a SQL query that displays the full name of the day of the week, the hour, minutes and seconds of the computer you are using.
Determine the amount of profit for order number 1004. Include the book title and the profit, with the profit formatted as dollars and cents. Use the paideach and cost columns to calculate the profit, and make sure to use the quantity purchased if there was more than one book purchased.
Using today's date, determine the length of time in months since each book was published. Display the title and publication date along with the number of months. Use an alias for the length of time.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
