Summing based on multiple criteria - google-sheets

I have a problem similar to the one described in Excel: Sum values based on values in another column and mapped values
Solution there works in excel but unfortunately it doesn't work in google sheets.
How can this be done in google sheets and does anyone know why excel solution is not working in google sheets?
Edit 1:
Per request I am duplicating relevant info here:
On each day a single sport activity is organized and attending students receive bonus points. Students can attend activities each day to receive points.
Based on existing columns I need to calculate total bonus points for each student (column I)

Try:I2
=ARRAYFORMULA(MMULT(--REGEXMATCH(TRANSPOSE(B2:INDEX(B:B,COUNTA(B:B))),H2:H8),IFERROR(VLOOKUP(C2:INDEX(C:C,COUNTA(C:C)),E:F,2,0),0)))

Related

How to add up values in an array if they need to meet numerous criteria

I am building a rudimentary budgeting tool on Google Sheets, where I intent to use a google form to enter new data(Data input sheet). After this I want to sum all expenses up, which timestamps are within the same year and month and have a common category like Technik or Nebenkosten(utility). This sum is supposed to go into a separate spreadsheet. SummaryOfExpenses How can this be made possible
I suggest that you build a pivot table and group the dates by year and monthes.
You can do it into a separate spreadsheet of course.

How can I count the number of items listed on a different google sheet based on dates in 2 different cells and if another cell is blank?

I have a google doc that tracks information about employee training (Example 1). I have another google doc that needs to summarize the information (Example 2) from multiple different sheets which mirror example 1 but for different teams.
Example 1: this sheet is tracking employees start dates, dates they finish training, and if they have quit. (there are multiple different docs all with the same format that I'm pulling from using importrange).
I need a formula that will count the number of employees currently in training. So count if start date is equal to or after today, end date is equal to or less than today, and the quit column is blank.
If the formula worked the way it should, and I was looking at the summary doc on 11/10/2021, it should report 4 people in the "# in Training" column on the table below (Example 2).
I have tried using an ArrayFormula with CountIfs to accomplish this, but it still pulls 0. Here is the formula I've been playing with:
=ArrayFormula(COUNTIFS('tracker'!$B$2:$B, "<="&TODAY(), 'tracker'!$C$2:$C, ">="&TODAY(), 'tracker'!$D$2:$D,""))
Give a try on below formula-
=COUNTIFS(B2:B8,"<=" & DATE(2021,11,10),C2:C8,">=" & DATE(2021,11,10),D2:D8,"")

How to do a VLOOKUP in another Google sheet based on a filtered value?

Basically I have a list of cars that I wish to hypothetically sell and captured the data in the Cars tab in this google sheet.
What I am trying to do is capture how many cars are for sale based on the car type and also consumer interest based on the car type. For example, how many "Y" the sports car has and store this total in a new tab called Consumer stats in this google sheet.
I dont know how to do a VLOOKUP so it extracts all the Y for consumer interest based on sports car for example
Any help will really mean a lot!
Thanks
Have you considered a pivot table? This seems like the perfect use case.
In your example sheet, I added 3 versions.
Your original ask, count of consumer interest by car type
Count of consumer interest by car type and model
Type and Model that have both interest and are for sale.
There are multiple tutorials online for how to set up pivot tables.
The pivot table can be more powerful if you used 0 and 1 for N and Y in your interest and for sale. Sheet's pivot tables don't do COUNTIF natively, and adding custom formulas seems like a lot of extra work.

Tracking Volunteer Hours Using Google Sheets

I'm trying to find an efficient way to keep track of volunteer hours for each member of a high school volunteer club using Google Sheets. Right now, I have four sheets, one for members of each grade. On the horizontal axis, I list every event and how many hours they volunteer for (or don't volunteer). However, it takes up a lot of columns and I end up having to continually add columns which is a pain, especially when passing the document on for the next "generation" of club officers.
I was thinking of having one sheet for all the members and another for all the events with names and hours of each person who volunteered. The only problem is, I want the main sheet to be able to search through the event sheet for a certain name and then add the hours that correspond to that found name to the total hours on the main sheet.
Is it even possible to search through a different sheet and return a value other than the index? To return a value in a cell next to that of the name?
There are many ways to do this. For a one function solution use QUERY.

Creating a new Google Spreadsheet based on results in two sources

Using the "importHTML" function, I've scraped two tables from the web, containing results from weekly 5k races. These two tables now exist as two sheets within a Google Spreadsheets document, each of which are titled "19/11/11" and "12/11/11".
These sheets contain several columns, the most important of which are NAME and GRADE (a percentage value that "scores" your time based on your age.
For example:
Max LANCASTER
81.83%
Craig MITCHELL
76.58%
Andy MCGHEE
73.16%
I'd like to be able to create a new sheet with data that looks at this week's results (19/11/11) and compares it to last weeks (12/11/11). If the runner did not compete the previous week, then they are ignored, but if they did, their NAME and GRADE (for both weeks) is shown. This would allow me to sort on GRADE, and find who was the most improved runner.
Can any Google Spreadsheet experts help me figure this one out?
Thanks
Ronnie
There's most likely better ways of doing this than what I'll suggest, but since no experts answered you... here I go!
I'll suppose NAME is on column A and GRADE on B.
In a new "compare" sheet, with the following header:
NAME - GRADE A - GRADE B - DIFF
I'd add these formulas on row 2.
A2: =Filter('19/11/11'!A2:B;Match('19/11/11'!A2:A;'12/11/11'!A:A;0))
C2: =ArrayFormula(Transpose(Split(Concatenate(If(A2:A=Transpose('12/11/11'!A2:A);Transpose('12/11/11'!B2:B);"")&If(Transpose(Row('12/11/11'!A2:A))=Rows('12/11/11'!A2:A)+1;Char(9);""));Char(9))))
D2: =ArrayFormula(FILTER(B2:B-C2:C;A2:A<>""))
And if I'd like the sorted result (as you mentioned), I'd do this:
F1: =Sort(A:D;4;false)

Resources