Question
This is in SQL. 5. Add a column to the query in question 4 that uses the RANK() function to return a column name BalanceRank
This is in SQL.
5. Add a column to the query in question 4 that uses the RANK() function to return a column name BalanceRank that ranks the balance due in descending order.
Bonus: Write a SELECT statement that returns two columns from the GLAccounts table: AccountNo and AccountDescription. The result set should have one row for each account number that has not been used in the InvoiceLineItems table. Order the results by AccountNo. We want to find general ledger account numbers that have not been used, yet. Hint: Start by writing a query that lists all of the distinct AccountNo values in the InvoiceLineItems table and use that as a subquery in the operand of the NOT IN operator.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started