Print Page | Close Window

Sort By Summary of Group

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=22560
Printed Date: 28 April 2024 at 12:03am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Sort By Summary of Group
Posted By: Shragel
Subject: Sort By Summary of Group
Date Posted: 19 March 2015 at 2:15pm
Is there a way to sort by the summary of the group.

For example we are grouping by state and want the group to sort based on the state that has the most orders.



Replies:
Posted By: olebed
Date Posted: 20 March 2015 at 4:21pm
Hello Shragel,

You can
1) add new auxiliary column with sum of orders
2) calc sum for every state and write it into auxiliary column.
3) group by this auxiliary column.

state orders sum orders of state
1 1 6
1 2 6
1 3 6
2 4 15
2 5 15
2 6 15

state orders
sum orders of state: 15
2 4
2 5
2 6
sum orders of state: 6
1 1
1 2
1 3





Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net