Sorting Rows while keeping rows Grouped by a specific column (Excel 2010)

robynn

New Member
Joined
Sep 24, 2014
Messages
2
Hi,

Below are the results of two columns of data (Red Zone Days and Project) which I sorted 3 times in in excel. The first 2 groups I used the integrated Excel sort function. The last group was sorted manually and is essentially what I am trying to achieve either through excels sort function, macro or vba routine. Does anyone have any suggestions? Also, just a note I'm trying to stay away from Excel's group functions as this spreadsheet contains large amounts of data which have to be sorted many different ways. Any suggestions are appreciated. :)



[TABLE="width: 1028"]
<tbody>[TR]
[TD]RED ZONE
DAYS[/TD]
[TD]PROJECT[/TD]
[TD][/TD]
[TD]RED ZONE
DAYS[/TD]
[TD]PROJECT[/TD]
[TD][/TD]
[TD]RED ZONE
DAYS[/TD]
[TD]PROJECT[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD] A[/TD]
[TD][/TD]
[TD]7[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]7[/TD]
[TD] CCC[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD] BB[/TD]
[TD][/TD]
[TD]8[/TD]
[TD] A[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD] BB[/TD]
[TD][/TD]
[TD]8[/TD]
[TD] BB[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] BB[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]8[/TD]
[TD] A[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]8[/TD]
[TD] BB[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] CCC[/TD]
[TD][/TD]
[TD]9[/TD]
[TD] BB[/TD]
[/TR]
[TR]
[TD="colspan: 2"]Sorted by:

Project (A to Z)
Red Zone Days (Small to Large)

Result: Projects are sorted alphabetically and do not float the Projects with the smallest Red Zone Days to the Top.[/TD]
[TD][/TD]
[TD="colspan: 2"]Sorted by:

Red Zone Days (Small to Large)
Project (A to Z)

Result: Projects Rows are no longer grouped together[/TD]
[TD][/TD]
[TD="colspan: 2"]Sorted by:

Manually

Result: Project rows are kept together yet sorted so that Projects which have the smallest number of Red Zone Days are sorted first. (So essentially, RedZone days are sorted from smallest to largest within the projects and then the project "groups" are sorted by Projects from the smallest to largest number of Red Zone days .[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN

Forum statistics

Threads
1,223,231
Messages
6,170,884
Members
452,364
Latest member
springate

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top