Forum Discussion

johnsboxftm's avatar
johnsboxftm
Brass Contributor
Mar 13, 2023

Which feature should I use for a sum of taxes collected for each city by name?

Hi all,

 

Your help is always appreciated, greatly.  I would like to add the sum of taxes collected for each city on a spreadsheet ... I have no idea of how to go about that.  Here is a pic of my current spreadsheet:

What I want to do is get a sum for all the taxes collected for each city

 

Like this, perhaps?

 

I'm not sure how to write the formula.  Please help.  And thank you in advance.

6 Replies

  • SammyFave's avatar
    SammyFave
    Copper Contributor

    If you're looking to sum taxes collected for each city by name, try using the SUMIF function in Excel. This function allows you to specify a range of cells to sum based on certain criteria, like the city name. However, if you're having trouble getting the data you need, consider using https://www.paystubcreator.net/. This website can help you generate accurate pay stubs that include information on taxes collected, making it easier to track your earnings and expenses.

  • johnsboxftm 

    In B30:

     

    =SUMIF($B$2:$B$26, A30, $G$2:$G$26)

     

    Fill down.

     

    Alternatively, create a pivot table based on the data, and add the City field to the Rows area and the Tax field to the Values area.

    • johnsboxftm's avatar
      johnsboxftm
      Brass Contributor
      I do have a table created with all the cities I have tax rates for ... I was hoping to have the formula automatically pull from that table's list of cities, then look at which of those cities I have on this particular sheet and then give me a grand total of $ in taxes
      • HansVogelaar's avatar
        HansVogelaar
        MVP

        johnsboxftm 

        A pivot table based on the data range in your first screenshot will automatically list only the cities that are present in that range.

Resources