I have 2 tables, the first holds points transactions for users and the second should hold a sum of points for each unique user.
There can be multiple points rows for a unique user in the first table.
I want to lookup the username stored in the second table, against the username in the first table to sum all points assigned to that user.
However, I only want to sum the points where Paid = Yes
It's out of my depth but I need it. Examples of the tables are below.
Thank you!!
USERNAME POINTS PAID deborah 100 yes michael 100 yes michael 200 yes simon 100 yes deborah 100 no michael 500 no
USERNAME POINTS deborah michael simon
Bookmarks