I suggest you ...

Totalize one or more column when filtered

It would be nice if we can have a row where totalize (sum, average etc.) the numeric columns, of course when the spreadsheet is filtered the totals reflect only the filtered rows.

214 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Marco shared this idea  ·   ·  Admin →

    16 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      Submitting...
      • Pat commented  · 

        @Amber It's not "whining", it's requesting a feature that many users would find very helpful. Given the IT limitations of some companies's it's not necessarily realistic to expect everyone to use Tableau or Data Studio. For example, my clinical research network operates across 30 different healthcare organisations, with many different IT systems and policies. Getting them all to agree to that is a very long shot indeed.

      • Anonymous commented  · 

        Hi, @Cristian Bogdan. I tried the script but it's not working. please help. Thanks

      • Amber commented  · 

        People, Awesome Table is analogous to AngularJS.
        What all of you are requesting is a METRICS DASHBOARD feature - which is not an Awesome Table scope.
        Use Tableau or Data Studio instead of whining.

      • Cristian Bogdan commented  · 

        You can add a script to your Template spreadsheet tab to accomplish this. Add a new template column (make sure to configure your awesome-table under "Advanced parameters" to include that template column). In the first row you write <script> and in the second row something like this

        setInterval(function(){
        var t=document.getElementsByClassName("google-visualization-table-table")[0];
        if(!t.querySelector("#TheSum")){
        var e = document.createElement('tr');
        e.setAttribute("style", "background-color:lightgray;");
        e.innerHTML = "<td colspan=5><span style='float:right;font-weight:bold;'>Total on page:</span></td><td id='TheSum'></td><td></td>";
        t.firstChild.nextSibling.appendChild(e);
        }
        var sum=0;
        var tds=document.getElementsByClassName("google-visualization-table-td-number");
        for(var x=0; x<tds.length; x++)sum+=parseInt(tds[x].firstChild.innerHTML);
        document.getElementById("TheSum").innerHTML="<span style='float:right;font-weight:bold;'>"+sum+"</span>";

        },1000);

        This will sum (every second) all the numbers in the table which is ok if you have only one numeric column. If you have more you will need to figure out which column is which. You can do that by retrieving the parent (<tr>) and checking which child index is the current <td>.

        Another limitation is that this is summing up only the numbers visible in the current result page. If your filter results in more pages and you want to sum for all, you can use the same <script> technique to retrieve a sum but then you will have to retrieve the numbers from google spreadsheets directly. May be doable, just look at the google spreadsheet API queries that awesome-table itself makes.

      • Anonymous commented  · 

        why there is no action up to now about this feature request

      • Pat commented  · 

        Yes please! SUM of filtered rows is exactly what I need.

      • Anonymous commented  · 

        Any updates on this request - I've seen a few work-around but haven't found one that works for us - we'd love to run our monthly commissions report in Awesome Table.

        Thanks!
        Adam

      • Jonathan Palmer commented  · 

        Just bumping this again - the lack of this feature is the only thing preventing wide acceptance and use of Awesome Table within my company.

      • Jonathan Palmer commented  · 

        Absolutely interested in this - Awesome Table could really turn into a valuable tool for those of us that want detailed information AND some basic summary information, not just visual summaries...

        It's basically the BIAggregate display option, but we need it in the Table View.

      • Anonymous commented  · 

        Can I have one, please? A million thanks in advance!

      • Anonymous commented  · 

        This would be more than usefull, please do so

      • Anonymous commented  · 

        I fully agree!
        Please, implement this Google!

      • David Milbrandt commented  · 

        I agree. This would make this tool 10 times more powerful than it already is.

      Feedback and Knowledge Base