I have data from employees in a table about who they are (name) and what their hourly billable rate is ($/hr). I also have a separate table, that has the time logs from a given time period. This table shows the person who logged the time, the job they logged it for, and the # of hours they logged.
I want to have a “Costs Log” Table that is updated when I click a button (end of each day/week or something). This button action should “go through” the Time Logs table, and for each job represented in the table (Rows), it should add up the hours for each employee in the hours column and multiply it by their hourly rate which is stored in a separate table. It’s important to note that I don’t want the jobs duplicated in the Costs table (if there are multiple entries in the Time Logs for the same job, the function needs to be able to combine them together and modify the row in the Costs table if it already exists.
I was able to do this without the final part (including the billable rate to get the $ amount), but I honestly don’t know enough yet to know how to approach this.
I have created a test document without my attempt because I don’t think my attempt really added value since I don’t really know the right way to do this.
I am very open to other ways of doing it. I just want the most efficient method for getting the costs of a project in a “Costs” table (and eventually I would like to figure out how to automate it so I don’t need the button - if that’s possible and reliable).