MineThatBird
New Member
- Joined
- Sep 9, 2013
- Messages
- 3
Here's what I'm working with...
I have an excel spreadsheet with nearly 15,000 rows that I'm trying to sort. Each row has 68 columns, and represents a single piece of equipment that my company has shipped out to various job sites. The rows are sorted according to ship date, in descending order.
Here's where it gets tricky...
Sometimes as many as 30 separate pieces of equipment will be shipped out to a job site, but they're not all shipped on the same day. Because of that, the rows with the same value in the "Job Name" column aren't always grouped together, and instead are scattered throughout the spreadsheet.
Here's what I'm trying to accomplish...
What I need to do is group all equipment rows that belong to the same "Job Name" together. HOWEVER, I must also keep those jobs sorted according to "Ship Date". That means not just the equipment (rows) within each job, but also the jobs themselves (all job-groups sorted in descending order according to ship date of most recent shipment in that particular job) . Does anyone know how to create a macro that can do that?
Here's an example of what the spreadsheet looks like now:
{Equip Type, Job Name, Ship Date}
CHILLER.....WESTSIDE MALL.....JAN 28
AIR HND.....WESTSIDE MALL.....JAN 27
CHILLER.....ELEM SCHOOL.........JAN 26
AIR HND.....WESTSIDE MALL......JAN 25
I-PAK..........ELEM SCHOOL.........JAN 24
I-PAK..........ELEM SCHOOL.........JAN 23
AIR HND......JOE'S FACTORY.......JAN 22
AIR HND......JOE'S FACTORY.......JAN 21
AIR HND......WESTSIDE MALL..... JAN 20
Here's how I need for it to look:
CHILLER.....WESTSIDE MALL.....JAN 28
AIR HND.....WESTSIDE MALL.....JAN 27
AIR HND.....WESTSIDE MALL.....JAN 25
AIR HND.....WESTSIDE MALL.....JAN 20
CHILLER.....ELEM SCHOOL........JAN 26
I-PAK.........ELEM SCHOOL........JAN 24
I-PAK.........ELEM SCHOOL........JAN 23
AIR HND.....JOE'S FACTORY......JAN 22
AIR HND.....JOE'S FACTORY......JAN 21
Anyone know how to write a macro that will accomplish this?
It's not enough to simply sort by Job Name then by Date… because although that does group all equipment (rows) pertaining to a particular job together, the jobs themselves (imagine the group of rows with a single job name as just 1 row) no longer appear in descending order according to each job’s most recent shipment.
Please advise. Thanks!
I have an excel spreadsheet with nearly 15,000 rows that I'm trying to sort. Each row has 68 columns, and represents a single piece of equipment that my company has shipped out to various job sites. The rows are sorted according to ship date, in descending order.
Here's where it gets tricky...
Sometimes as many as 30 separate pieces of equipment will be shipped out to a job site, but they're not all shipped on the same day. Because of that, the rows with the same value in the "Job Name" column aren't always grouped together, and instead are scattered throughout the spreadsheet.
Here's what I'm trying to accomplish...
What I need to do is group all equipment rows that belong to the same "Job Name" together. HOWEVER, I must also keep those jobs sorted according to "Ship Date". That means not just the equipment (rows) within each job, but also the jobs themselves (all job-groups sorted in descending order according to ship date of most recent shipment in that particular job) . Does anyone know how to create a macro that can do that?
Here's an example of what the spreadsheet looks like now:
{Equip Type, Job Name, Ship Date}
CHILLER.....WESTSIDE MALL.....JAN 28
AIR HND.....WESTSIDE MALL.....JAN 27
CHILLER.....ELEM SCHOOL.........JAN 26
AIR HND.....WESTSIDE MALL......JAN 25
I-PAK..........ELEM SCHOOL.........JAN 24
I-PAK..........ELEM SCHOOL.........JAN 23
AIR HND......JOE'S FACTORY.......JAN 22
AIR HND......JOE'S FACTORY.......JAN 21
AIR HND......WESTSIDE MALL..... JAN 20
Here's how I need for it to look:
CHILLER.....WESTSIDE MALL.....JAN 28
AIR HND.....WESTSIDE MALL.....JAN 27
AIR HND.....WESTSIDE MALL.....JAN 25
AIR HND.....WESTSIDE MALL.....JAN 20
CHILLER.....ELEM SCHOOL........JAN 26
I-PAK.........ELEM SCHOOL........JAN 24
I-PAK.........ELEM SCHOOL........JAN 23
AIR HND.....JOE'S FACTORY......JAN 22
AIR HND.....JOE'S FACTORY......JAN 21
Anyone know how to write a macro that will accomplish this?
It's not enough to simply sort by Job Name then by Date… because although that does group all equipment (rows) pertaining to a particular job together, the jobs themselves (imagine the group of rows with a single job name as just 1 row) no longer appear in descending order according to each job’s most recent shipment.
Please advise. Thanks!