Example SQL Table:
ID | USER | AMOUNT_SALES | TOTAL
--------------------------------
1 | John | 1500 | 2000
2 | John | 1400 | 3000
3 | James| 1200 | 4000
4 | John | 1100 | 5000
5 | Anie | 1900 | 8000
So I want to
SELECT * FROM table
and show the results on HTML table using while, but I don't want to repeat the users.
Example table I want to create:
User | Amount Sales | Total
-----------------------------
John | 4000 | 10000
James | 1200 | 4000
Anie | 1900 | 8000