Reference no: EM13869141
Using MySQL SELECT commands answer the questions listed below using the Tiny Video schema used in your previous assignment. Submit via the D2L dropbox the final SQL script for each problem. All questions are worth 2 points each.
1. Write a query to display the columns listed below. The query should list each customer once, whether they have rented a movie or not. Where the customer has rented a movie it should show only the first rental date. The output should be sorted by membership number.

2. Write a query to display the columns listed below. The query should list each customer who has not rented a move. The output should be sorted by membership number.

3. Write a query to display the columns listed below. The query should list each customer where the total detail rental fee is greater than twice the overall average detail rental fee. The output should be sorted by membership number. (Hint: A HAVING clause will be needed)

4. Write a query to display the columns listed below. The query should list each customer in which the video rental is overdue. The Days_Overdue column should calculate the number of days overdue based upon the due date and return date. The output should be sorted by membership number and then by the detail due date.

5. Write a query to display the columns listed below. For each customer the query should show the current system date, the current day (when you do the problem the date and day will be different), the number of characters in the member last name, the last date the customer rented a video and how many total videos the person rented.

Attachment:- scripts.rar
The speed with which it hits the ground
: A person stands on the edge of a roof 490m above the ground and throws a stone horizontally with an initial speed of 15 m/s. Neglecting air resistance. find (a) the time taken by the stone to reach the ground. and (b) the speed with which it hits the..
|
What is the purpose of a cross join in mdx
: What is the purpose of a cross join in MDX? Specifically, what gets returned as the result of a cross join.
|
Compute how much total expenditures the state
: A state whose fiscal year ends June 30, 2013, had the following transactions and events. For each item, compute how much total expenditures the state will report in the General Fund Statement of revenues, expenditures and changes in fund balance f..
|
Calculate the maximum velocity it attains
: The acceleration of a motorcycle is given by ax (t) = At - Bt2, where A = 1.50 m/s3 and B = 0.120 m/s'. The motor cycle is at rest at the origin at time t =0 a) Find its position and velocity as functions of time b) Calculate the maximum velocity it ..
|
Write a query to display the columns listed
: Write a query to display the columns listed below. The query should list each customer once, whether they have rented a movie or not. Where the customer has rented a movie it should show only the first rental date. The output should be sorted by m..
|
Accounting for construction costs
: Wells Corporation uses the percentage of completion method of accounting for construction costs. For Construction Project A, Wells had previously recognized revenue of $250,000 out of a total of $800,000 for the project.
|
How can i design a distributed shared memory over sockets
: How can I design a distributed shared memory over sockets? Using two or more computers, i want project includedistributed system shared memory between to computer.
|
Inputs to maximize short-run profits
: A price taking firm chooses its inputs to maximize short-run profits. Its Cobb-Douglass production function has the following form: q(L, K) = L ^(1/2)K^(1/3) . The output price is 1,000 per unit and the cost of each unit of input is 10. In the short-..
|
The angle between the direction of a and positive direction
: The x and y components of a vector A are -25.0 m +40.0 m. respective y. What is the angle between the direction of A and positive direction of x?
|