AdvancedFinanceSQL+20 XP
Grouped Reporting: amount at least 313
Scenario
You are a data professional working with finance data. Prepare a reliable reusable result from payments for a review.
Question
Group qualifying records by payment_id, add amount in each group, and show the highest total first. Keep values at or above 313.
Your task
- Inspect the provided data and column names
- Group qualifying records by payment_id, add amount in each group, and show the highest total first. Keep values at or above 313.
- Run your code and compare the result
Grouped ReportingSQL
Read the simple theory: SQLAdvanced · Duplicate Removal & Result Sampling — question 20 of 20
1. Choose your dataset
Pick an industry and a size. Your code and results change to match.
sql editorpayments
Snippets
💡 Explain my whole code, line by line (hover any word in the editor for a tip)
🌈 In short — no coding words
📂 Opens the "payments" table→✅ Shows you the answer
Altogether: this query reads your industry table, picks what you need, and shows the answer as rows.
Start typing to see suggestions. Press Enter to use one. Red marks show the line to fix. Drag a bottom corner horizontally and vertically to resize.
Type your code here ↓
✍️ Tap here to type
Dataset & schema
payments
The tiny starter data. Bigger data scrolls.
Fields
| payment_id | region | amount |
|---|---|---|
| P1 | North | 500 |
| P2 | South | 200 |
| P3 | North | 900 |
| P4 | East | 300 |
Finance practice data only.
attempts: 0
▶ Output terminal
$ Press “Check my answer” — results appear here.Your next steps
Each item turns green when your answer includes it.
- Reads the correct table
- Applies the threshold
- Uses the required operation