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

Data Analysis Spreadsheet Basics Getting Started With Spreadsheets Getting Started With Spreadsheets Review

Filter applied, only the categories F&B and Entertainment selected, =SUM(B5:B176), result: $9,431.00. What's wrong?

The question:

"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: $"

(Spreadsheet Basics, review questions Part 2, Treehouse)

I applied the process I posted as title to this post and got the result $9,431.00. The answer is not correct and would like to understand why.

Best regards

Murilo

2 Answers

Thank you Kris, this helped to see that I was actually doing right with selecting the categories/rows based on (B176-B5 = 171 items) but not the way finding the result.

I found out that I cannot use =SUM() with filter, because as the tutor said the items are only hidden, not gone, so it was still summing the hidden items, although in the bottom of the page it was displaying the right result. I got the message in the video, I guess, but it was not said explicitly that =SUM() should not be used with filtered content. Sort of should have deduced.

For filtered content, I should use a =SUBTOTAL() function instead.

(https://www.techrepublic.com/blog/microsoft-office/how-to-sum-values-in-an-excel-filtered-list/).

Best regards

Murilo

Check your filter. You must be including some additional categories/rows (B176-B5 = 171 items) as your value is too high. With the filter applied I had 113 items with a total sum of 3583.00 which was correct.