A beginner's workflow question

A beginner's workflow question

I have a table that has one record per day. Each record contains the date, total sales for the day, and total cost for the day.

I update the table with new information daily and would like to routinely generate the cost % of various ranges of days (week, month, etc). What is the most efficient way to do this?

I assume there will be some querying involved, I am versed in SQL, I just need help with the most efficient path from A to B in Zoho.