Question: Query 1 Write a SQL query that returns the service ID, service description, how many times the service was done (total service count) Use aliases
Query 1
Write a SQL query that returns
the service ID,
service description,
how many times the service was done (total service count)
Use aliases where appropriate
Order the result
Query 2 Write a query that returns
the name of the customer
and the number of orders placed
Use aliases where appropriate
Order the result
Query 3
Write a query that determines
how many payment records exist for each payment type (# visa, MC, checking etc).
Display the payment type and the count
Use aliases where appropriate
Order the result
\begin{tabular}{|l|l|} \hline \multicolumn{2}{|c|}{ LOCATION } \\ \hline PK & LocationID \\ \hline & LocStreetNum \\ LocStreetName \\ LocCity \\ LocState \\ LocZip \\ LocEmail \\ LocPhone \\ CreatedDate \\ \hline \end{tabular} \begin{tabular}{|l|l|} \hline \multicolumn{2}{|c|}{ INVOICE } \\ \hline PK & InvoicelD \\ \hline FK & CustomerlD \\ FK & OrderID \\ FK & EmployeelD \\ & SubTotal \\ TaxAmount \\ TotalAmount \\ InvoiceDate \\ \hline \end{tabular} \begin{tabular}{|l|l|} \hline \multicolumn{2}{|c|}{ CATEGORY_SVC } \\ \hline PK & CategoryID \\ \hline & CategoryName \\ \hline \end{tabular}
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
