I have a Google Sheets spreadsheet which is connected to an external integration that automatically populates rows with new 'events' contained within one of the sheets. I want to create a second sheet that contains formulas which automatically aggregates the counts of these events, with a few caveats. It is probably easiest to explain the problem with a few pictures. Here is what the input sheet data looks like (simplified):
So as you can see, each event row contains a unique event ID, some date fields, a user ID, and a user name. What I ultimately want to do is count how many events were created by each user, each month. So the desired output would look something like this:
I think that maybe I accomplish this with a COUNTIFS
function somehow? But there is one critical caveat: sometimes the integration that adds rows to the input event list screws up and adds duplicate rows. I show this above in my screenshot where you can see that rows 3 & 4 are identical, both with the same event ID of 126. Is there some way I can make the formula smart enough so that it automatically filters out any accidental duplicates like this?