Scenario: I'm doing some pro-bono work for a school that has a summer camp enrollment spreadsheet, similar to the table labelled "Example Source":
In order to maintain accurate attendance, the school wants a per-class roster that each teacher can use to determine who's expected to be in attendance on a given day. This can be error-prone because, unlike in my example, the real source has dozens of classes.
In past years, they've manually generated the roster for each class by creating separate docs for each class and hand-typing the student names based on the enrollment sheet. My goal is to automate this process — in Google Sheets or Excel, but pref. G Sheets — in order to save the staff time and typos.
The x/X/o entries shown in the sample data is meant to account for the high likelihood of inconsistent data entry…ideally, any non-blank entry on the left should result in the student's name appearing on the right.
Question
Given the sample data, how can I automatically populate columns G:I, accounting human data entry inconsistencies as represented by the x/X/o in columns B:D?
you could either do simple mirror mapping like:
=ARRAYFORMULA(IF(B4:D<>"", A4:A, ))
or something more compact like:
=ARRAYFORMULA({SORT(IF(B4:B<>"", A4:A, )),
SORT(IF(C4:C<>"", A4:A, )),
SORT(IF(D4:D<>"", A4:A, ))})
Related
I have a sheet that has 5 columns, with what I will "Features" - Vegan, Non GMO, Soy Free, Dairy Free, Gluten Free.
For each product entry, I have setup simple true/false data validation based on whether that product meets the metric.
To the right, you can see a "Features" column. What I want to do is create a filter on that features column that will display products on a website based on whether any metric is meet, ie whether the product is vegan, non gmo etc
You can see what im trying to do over at VitaminSpecs. You can see the last filter currently returns "null" due to no data, but thats where I want to list "Vegan" "Non GMO" etc and allow customers to be able to multi-select those metrics
Update: From the formula provided by Player0, I am able to generate the following in the spreadsheet and on website
Spreadsheet
Filter
try in T2:
=INDEX(REGEXREPLACE(TRIM(FLATTEN(QUERY(TRANSPOSE(
IF(O2:S=TRUE, O1:S1&",", )),,9^9))), ",$", ))
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.
I'm using multiple Google Sheets to set up a logging system for the transfer of students between classrooms during a study period. A master spreadsheet (I call it Spreadsheet A) contains a record of all the students in the building and the teacher to whom they are assigned, and each teacher has their own separate spreadsheet (Spreadsheets B1, B2, etc.) tracking only the students assigned to them. There are more than 100, which is why I opted for separate spreadsheets rather than giving each teacher a tabbed page in Spreadsheet A.
Teachers can request that a specific student be sent to them for help by entering their name next to the student's name on the master list (Spreadsheet A). When this happens, the student's name is added to a list on the spreadsheet of the teacher making the request (so that's Spreadsheet B1). Separately, the student's regular homeroom teacher sees the student's name highlighted on their page (Spreadsheet B2), and sees which teacher made the request. Spreadsheet A feeds all the information to the various Spreadsheet Bs
This is all done and built. However, we want to include a time-tracking function, to make sure that students are moving in a timely fashion and not disappearing. Currently, the teacher receiving the student enters the time they showed up on Spreadsheet A, but this is cumbersome. The teachers want a way to enter arrival times on their own pages, and have it visible to the sending teacher & the administration.
So, I want the main Spreadsheet A to pull data from teachers' Spreadsheet Bs, look for students who have arrival times listed, and then copy those arrival times into a data column next to the students' names on the master list on Spreadsheet A. That will, in turn, propagate out to their homeroom teacher and administrator, so they can see who's coming and going, and how long it's taking them.
Oh, and there are nearly 2,000 students, so there's no way to put in a search string name by name. It has to be a blanket formula that says:
If there is data in column K (an arrival time) on Spreadsheet B1 (and all other B-series spreadsheets),
Then use the data in column H (the student's name),
Find a match on the master list on Spreadsheet A,
And copy that data from Spreadsheet B1 into column F (Arrival time test) on Spreadsheet A, next to the appropriate student, but
Do nothing if there is no data in column K.
Is this even possible?
Test demonstration page:
https://docs.google.com/spreadsheets/d/1F2HYmGv8Vfw9TDeAI2eNmv73jCD-lWcfhKZvWM8-r58/edit#gid=0
The pages for each teacher can be opened from the links in the second page tab.
So far, I've tried to compile all of the data from the existing teacher spreadsheets (B1, B2, etc.) into one list as a page on Spreadsheet A. I thought this would then make it easier to match the names and times, but it always throws an error message, no matter what formula variation I try.
=QUERY({Importrange("1y4GjGnUK9usYCNnSClYl2piFgMlbn07wWClrgZnl6Ms","’Teacher page’!H6:K");Importrange("1dNNZR0GvskBU2WG2N348EGFDbHN2aK9kWmxhoQNmn2M","’Teacher page’!H6:K")},"Select Col1, Col2, Col3, Col4 where Col1 is not null ")
This produces: "Unable to parse query string for Function QUERY parameter 2: NO_COLUMN: Col2"
=QUERY({IMPORTRANGE("1y4GjGnUK9usYCNnSClYl2piFgMlbn07wWClrgZnl6Ms","Teacher page!H6:K");IMPORTRANGE("1dNNZR0GvskBU2WG2N348EGFDbHN2aK9kWmxhoQNmn2M","Teacher page!H6:K");IMPORTRANGE("1buhv3AAi6apWIg_-uZv_BzDvyOEvpkxTmO5is-Yhxi4","Teacher page!H6:K");IMPORTRANGE("1b-kEed3zFcZIg3eldcT0x0JXgiwfWNUou_N0ntPsVEg","Teacher page!H6:K")})
This produces a result, but only from the first Spreadsheet B (B1) queried. It doesn't include the results from the other three sheets in the test version. I still have no idea how I'd merge the data from that data collection to the original master list.
I have a google spreadsheet that is being used to develop student schedules. Students are separated into one of two "houses" of teachers on the grade level roster sheet, then each house is scheduled on another sheet in the workbook.
I need to generate a list of students who are marked for "beta" house on the grade level roster (students from all houses), but whose names are not yet listed on the house scheduling sheet.
I have tried
=Unique(Filter(Roster!A:A&A3:A30,Roster!B:B="Beta"))
as well as
=Filter(Roster!A:A,Roster!B:B="Beta",<>A3:A30)
I made some loose attempts with the Query function, but I really have no idea what I am doing with that function yet.
The reason for the inconsistent range sizes is that students with special needs are scheduled first, and then other students (Speech/504/ELL) are scheduled as another layer of the process.
The Grade level roster sheet:
The House scheduling sheet:
=Filter(Roster!A:A,Roster!B:B="Beta",ISNA(MATCH(Roster!A:A,A3:A30,0)))
I have two simple table in Excel 2010 - Products and Sales:
I then linked them into PowerPivot - and here created the relationship from Sales.ProductId to Products.Id - like this:
Now I'm trying to build a Pivot that for each productId in the Sales table also shows me the Category and the PurchasePrice from the ProductTable. However, here I'm stuck - because the relationship is somehow faulty. When configuring the Pivot, I get a message Relationship may be needed even if the relationship already exists. The resulting - wrong - pivot table looks like this:
though I'm actually trying to achieve this:
I know that I could create calculated columns in the Sales table of PowerPivot and pull all required data using the RELATED DAX function - but as the real world project requires a lot of joins and fields I'm hoping that there's a better solution than this workaround...
I uploaded the example file here.
Peter,
Your question was a bit more tricky than I first though and I spent quite some time digging around, but I think I found the solution after reading this article about making distinct count in related tables.
I have updated your source file (so that Sales table contains more than 1 sales per product) and uploaded it to my public Dropbox folder.
You can see that I created 4 new calculated measures to illustrate my solution and to make it a bit easier to understand (Excel 2010 terminology, in 2013 it's Calculated Field):
Sales Price Total
=SUM(Sales[SalesPrice])
Products Sold
=COUNT(Sales[ProductId])
Purchase Price per Item
=CALCULATE(SUM(Products[PurchasePrice]),Sales)
Purchase Price Total
=[Purchase Price per Item] * [Product Sold]
The key difference here is the formula for calculating purchase price per item. The reason why you should SUM the product purchase price within CALCULATE function is explained in great detail in the linked article (even though in a bit different context):
In this way, any filter active on Sales (the related table) propagates
to the lookup table.
There might be some other parts I missed, but I have tried this in couple other examples and it simply works as it should: