Aggregation troubles

How do I aggregate the sum of records in one field from one table to one record in another table? The key condition is that the Unique ID should match in both tables before the aggregation. So if the Unique ID is the same, only then the aggregation should happen.

I have attempted multiple hacks and read all about RollUps and Conditional RollUps, but still cannot figure this out.