Revenue for Every User
The product mart must show revenue for every user from a_users. Sum amount from a_events only for kind = 'purchase'; if there are no purchases, show 0. Return id and revenue, sorted by id.
Sagaidāmais izvades paraugs
Tā izskatās pareiza atbilde — tās rindu skaits ir pašai savs, tam nav jāatbilst shēmas tabulām.
| id | revenue |
|---|---|
| 1 | 50 |
| 2 | 0 |
| 3 | 50 |
Pieslēdzies, lai redzētu iesniegumu vēsturi
PieslēgtiesPieslēdzies, lai izmantotu AI mentoru
Pieslēgties