adding decimal values

I have a list of expenses and I want to be able to filter them by month/year and type then add all the decimal values and display that number in the front end.

I would like to be able to store this number in a secondary table with both type and month/year, so I can use it in the frontend with a filter for month and type. Is this possible or do I need to find a different way to go about this.

2 replies