The orders table records the month of each order.
Return order_id, order_month, amount for orders placed in months 1, 2, or 3. Sort by order_id ascending.
These DataFrames are passed to solve(spark, dfs). Access one with dfs['name'].
orders6 rows| order_id (int) | order_month (int) | amount (double) |
|---|---|---|
| 1 | 1 | 40 |
| 2 | 2 | 25.5 |
| 3 | 4 | 80 |
| 4 | 3 | 12 |
| 5 | 5 | 60 |
| 6 | 1 | 99 |
Column names and order must match. Sort order is specified in the question.