Back to problems

Transactions Status Report SQL

SQL · Intuit · Medium

Requirements Given a table named transactions, write a SQL query that returns the following columns: The query must: Convert raw failure reasons into normalized values. Count the occurrences of each normalized reason within each status. Apply a window function to rank reasons separately for every status. Use LISTAGG to combine the reasons so the result contains one row for each status. Report the total number of transactions and the total amount for every status. Examples…

Checking your access…