I have a table that has different % values for days in a cycle:
1 5%
2 10%
3 30%
4 10%
5 15%
6 15%
7 15%
I have another table that has different specific days and corresponding dates:
6/17/19 1
6/23/19 7
6/27/19 4
7/01/19 7
For every pair in the second table (i.e [1,7] & [4,7]) I would like the sum of percentages from the 1st to 7th day and 4th to 7th day, respectively in the first table.
I considered joining the tables but that doesn't help with the issue of summing a column based on conditions from another column. what functions could be useful for this?