Provide SQL statements and the query output for the following: No 1 2 3 4 5...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Provide SQL statements and the query output for the following: No 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 Question Display all the customers having full names longer than 10 characters. List all the names of the customers if their names contain the string 'ON', ignoring the case. Which plan has the highest number of cancelled phone numbers? How many customers have more than one active phone number? Generate a report displaying the total number of customers by each state. Is there any staff who is also a customer? Write an SQL query to support your answer. Display the supervisor's details and the total number of staff they supervise. List all the staff who are not supervisors. Did the total number of calls increase during the COVID lockdown period (2020) compared to 2019? Substantiate your answer with an SQL query. What is the second least popular phone colour among customers? List all the customers who are not active. A customer should be considered not active if they have no active phone number registered under their name. What plan is most popular among customers who are born before the 1960s? Write a query to display the total income generated by the company in 2019 from call charges based on gender. Assume call duration is recorded in seconds and calls are charged per minute. Is there any mobile plan in the plan table that has never been used? Show this using i. Sub-query ii. Joins Which tower(s) were used by customer 20010 to make the first call? Did any customer break their mobile plan before the mobile plan duration ends? Assume the plan duration is in months. Justify your answer with an SQL query by producing a list of customers who cancelled the plan before the duration expires. i. Create a view showing the popularity of phone colours based on the total number of active users. Use this view to show the least popular colour. ii. Provide SQL statements and the query output for the following: No 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 Question Display all the customers having full names longer than 10 characters. List all the names of the customers if their names contain the string 'ON', ignoring the case. Which plan has the highest number of cancelled phone numbers? How many customers have more than one active phone number? Generate a report displaying the total number of customers by each state. Is there any staff who is also a customer? Write an SQL query to support your answer. Display the supervisor's details and the total number of staff they supervise. List all the staff who are not supervisors. Did the total number of calls increase during the COVID lockdown period (2020) compared to 2019? Substantiate your answer with an SQL query. What is the second least popular phone colour among customers? List all the customers who are not active. A customer should be considered not active if they have no active phone number registered under their name. What plan is most popular among customers who are born before the 1960s? Write a query to display the total income generated by the company in 2019 from call charges based on gender. Assume call duration is recorded in seconds and calls are charged per minute. Is there any mobile plan in the plan table that has never been used? Show this using i. Sub-query ii. Joins Which tower(s) were used by customer 20010 to make the first call? Did any customer break their mobile plan before the mobile plan duration ends? Assume the plan duration is in months. Justify your answer with an SQL query by producing a list of customers who cancelled the plan before the duration expires. i. Create a view showing the popularity of phone colours based on the total number of active users. Use this view to show the least popular colour. ii.
Expert Answer:
Answer rating: 100% (QA)
Here are SQL statements and query outputs for the requested tasks Display all the customers having full names longer than 10 characters sql SELECT FROM customers WHERE LENGTHCONCATfirstname lastname 1... View the full 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
-
Assume that apples are an inferior good. Draw a perfectly competitive market for apples and a firm selling apples in the long run equilibrium where price is $10 and the firm's equilibrium quantity is...
-
On April 23, 2022, Protanica Company, a florist, purchased $112,000 of merchandise, terms were 3/15, n/45 from Botail Garden Center. Protanica returned $7,500 of damaged merchandise to Botail, which...
-
Silas is farsighted and wants to read the newspaper. Withoutglasses, Silass near point (the closest point he can see in focus)is far away, so he has to try to read the paper by holding his...
-
What are the concepts of traditional and contemporary organizational design? Will these designs be influenced differently by management and the environment?
-
Write condensed and bond-line formulas for the five isomeric C6H14 alkanes.
-
St. Paul Lumber Company incurs a cost of $280 per hundred board feet in processing certain "rough-cut" lumber, which it sells for $320 per hundred board feet. An alternative is to produce a "finished...
-
An automobile engine has a maximum power output of \(70 \mathrm{hp}\), which occurs at an engine speed of \(2200 \mathrm{rpm}\). A \(10 \%\) power loss occurs through the transmission and...
-
The unadjusted and adjusted trial balances for Editorial Services Co. on March 31, 2014, are shown below. Journalize the five entries that adjusted the accounts at March 31, 2014. None of the...
-
Law is a pervasive part of our lives; regulations shape our daily activities, govern our interactions with one another and our relationships to the planet and to other nations. Often our legal...
-
P6. (6 pts) Consider a generator of a CRC scheme 1010011 (i.e., x6+x++x+1). The message is 00110011 10001010. Answer the following questions. a. Compute the CRC bits for this packet (ignoring all...
-
AJ Pty. Ltd. is in need of $100,000 additional financing to support expansion plans. As owner-manager of AJ, you are uncertain about whether you should provide the firm with a loan or with additional...
-
What is the formula to find total dividend and payout ratio? This is the information I have: the amount of shares the company holds and the last dividend paid. Lastly, will there be enough cash to...
-
Define a function similar to the built-in reverse function, except that it acts recursively, reversing the order the members of any nested sublists. You may not use the built-in reverse function as a...
-
(a) Fill in the missing amounts. Assume that there are no nonoperating activites. Sales revenue Sales returns and allowances $ Net sales Cost of goods sold Gross profit Pharoah Company $96.980 $ (a)...
-
Compute the value of the following. (Assume n is an integer.) (3), f for n 3
-
Define (4 points) the following and explain the use/role (2 points) with an example in C++ (4 points). a) Object-Oriented Paradigm (10 points) b) Data Abstraction (10 points)
-
Which of the following will form non-ideal solution ? (a) CH5OH and water (c) CHCl3 and CH, COCH (b) HNO3 and water (d) C H and C HCH3
-
Economic feasibility is an important guideline in designing cost accounting systems. Do you agree? Explain.
-
Ann hires a nanny to watch her two children while she works at a local hospital. She pays the 19-year-old nanny $125 per week for 48 weeks during the current year. a. What is the employer's portion...
-
Larry and Lisa Williams, both 33 years old, have been married for 9 years. They live at 638 Arctic Way, Fairbanks, AK 99701. Lisa's Social Security number is 445- 81-1423 and Larry's is 798-09-8526....
-
Charlie's Green Lawn Care is a cash basis taxpayer. Charlie Adame, the sole proprietor, is considering delaying some of his December 2012 customer billings for lawn care into the next year. In...
-
Financial items for George Karatsis IT Services on 31 May 2024 are presented below in alphabetical order. Required (a) Prepare a statement of financial position similar to the one in figure 2.2. (b)...
-
Rebecca Tallance operates a rent a dress business from her home. She keeps her accounting records for business activities completely separate from her records for personal activities. At 30 June...
-
During the year ended 30 June 2024, Skilled Services, a provider of temporary secretary personnel, had collected receipts from clients for a total value of \($250000.\) Wages of \($136000\) had been...
Study smarter with the SolutionInn App