Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial![](https://ecs-static.teamtreehouse.com/assets/views/marketing/shared/community-banner-white-47072046c51352fe6a69f5e691ff5700b28bb11d45197d7bdf066d9ea3f72d0c.webp)
![Louis Espinoza](https://secure.gravatar.com/avatar/67aac141f6296dddc51fa681684558d9?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Louis Espinoza
217 PointsI am stuck on this Spreadsheet Basics Quiz
The Question is... In the Expenses spreadsheet you opened in the first question, the total dollar value of all items in the F&B and Entertainment categories is: $
When I use a filter in Sheets and unselect every category besides F&B and Entertainment and use the SUM function to calculate the total value I get $9,431.00. This however seems to be incorrect. Any help would be much appreciated.
2 Answers
![Brandon White](https://uploads.teamtreehouse.com/production/profile-photos/10746138/micro_4228B6A1-B7B6-47B8-9D23-EB9C488C56CC.jpg)
Brandon White
Full Stack JavaScript Techdegree Graduate 34,662 PointsHi Louis,
I’m pretty sure filter only hides certain rows from the sheet from your view, it doesn’t make it as so they (or their values) temporarily don’t exist. And so if you’re using the SUM function and you’re dragging across the entire column, you’ll still be including every value in the column (even the ones that you can’t see).
I’m pretty sure when I did this quiz I went through and clicked every value I wanted to include individually, but it would probably be cleaner to use a SUMIF function, then you can use the logic that sums the value if the category column for that row is equal to F&B and Entertainment.
I’m sure there are many other ways to solve this as well.
![Michael Hicks](https://uploads.teamtreehouse.com/production/profile-photos/1045202/micro_avatar.jpg)
Michael Hicks
24,124 PointsHonestly, this one was a big pain in the groin. The SUMIF function isn't covered in the video, so I understand your frustration Louis Espinoza. I watched a couple YouTube videos to get a better grasp of the SUMIF function and it helped me; links below.
In short, use the SUMIF statement separately on the F&B and Entertainment categories and then combined the results of the two with the SUM function. Here are the references to the helpful videos: How to use the SUMIF function in Excel & How to SUMIFS With Multiple Criteria In the SAME Column in Excel