I am hoping someone more experienced could give me some advice on how best to proceed with this:
I have a large table with columns C1, C2, C3, .... Cx I have a user defined filter, e.g. select those where C1 = "active" and C2 > 2017.01.01. I have already implemented this, based on user input, i am dynamically building my query. Now I would like to enable users to build dynamic reports with grouping, counting, etc, e.g. 1. User specifies C3 to be grouped on 2. User also specifies C4 to be grouped on 3. User wants to see count on those 4. User also wants, for each group and sub-group, the sum of C5 Example output would be: C3 C4 Count Sum_of_C5 Italy Verona 3 145 Italy Palermo 12 230 France Toulon 1 2 France Paris 102 240 (Meaning, there are 3 items from Verona, Italy, and the sum of column C5 for those 3 items is 145, etc.) Remember all of this is dynamically user specified: what columns to group on (C3 and C4, and what columns to sum, in this case, C5) I am sure there are several ways of achieving this. I am hoping someone has some idea on how to make this as easy as possible. Thank you. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.