'Group results from tables connecting customerID with customer FistName

Good day, I am completely new to SQL and I have a question. I am using MySQL and I want to do the following:

Suppose I have the following tables: customer:

CustomerID (PK) | FirstName | LastName | PhoneNumer 1 | Sally |Smith | 345-345-4567 2 | Brandon |Harris |512-467-8306

transaction:

TransactionID (PK) | CustomerID | TotalPrice | DateOrdered
100 | 1 |200 | 12/17/2021 200 | 2 |300 | 12/18/2021

I want to have a query that groups all customers BY NAME and shows the total amount of money they spent.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source