Sort on multiple levels

G

Guest

Hello. I have a query that I want to sort on multiple levles at the same
time. Fields that I want to sort on include include: Container, Warehouse,
Aisle, Section, Shelf, and Position. Query records may contain the same
Container value but different location infomation. I want to sort by Whse,
Aisle, Section, Shelf, and then Position BUT if there is more than one record
for the same container, I want to group all like containers together before
continuing the sort on location information.

Any help is greatly appreciated.
Thanks, Chris
 
G

Guest

Have you tried the GroupBy option and then the sorting opion. The groupby
option is the Sigma-sign in the menubar from the query

hth
 
G

Guest

I have but not with success yet. I think I need some more specific help.
Here is a small subset of my query data:

Case Lt Asl Sec Shf Date Whse
062172946 HB 20 24 9 70608 4
062174073 HB 19 30 7 70702 67
062174073 HB 3 10 8 70629 67
062174073 HB 32 34 8 70709 67
062174073 HB 48 4 2 70628 67
062174113 HB 3 22 6 70614 44
062175930 HB 3 30 6 70622 67
062175930 HB 30 42 5 70628 67
062175930 HB 36 21 8 70624 67
062179095 HB 19 13 2 70629 4
577630574 HB 1 26 7 70619 4
625587943 HB 3 31 9 70702 67

I want to sort by Lt, then Asl, then Sec, then Shf but I want to keep like
containers together. I am trying to organize the data as follows:


Case Lt Asl Sec Shf Date Whse
577630574 HB 1 26 7 70619 4

062174073 HB 3 10 8 70629 67
062174073 HB 19 30 7 70702 67
062174073 HB 32 34 8 70709 67
062174073 HB 48 4 2 70628 67

062174113 HB 3 22 6 70614 44

062175930 HB 3 30 6 70622 67
062175930 HB 30 42 5 70628 67
062175930 HB 36 21 8 70624 67

625587943 HB 3 31 9 70702 67
062179095 HB 19 13 2 70629 4
062172946 HB 20 24 9 70608 4


So that groups of the same container are sorted by the lowest location along
with records where there is only one location per container.
 
G

Guest

Sorry, I am using "Case" and "Container" interchangebely. The last 3 cases
are actually where I want them. I have manually configured the data for to
show what I am trying to achieve.

If there are 3 of the same case numbers, they are sorted as a group in
relation to all other case numbers based on the lowest location of the case
in that group. So all records for case 062174073 are sorted as a group based
on the location HB 3 10 8 in relation to case 062174113 in location HB 3 22
6, then the group of cases for 062175930 because that group of cases starts
with the next lowest location, HB 3 31 9. Followed by the next three cases.
 
G

Guest

Hi Chris,

I believe that this is a case of placing the fields in the right order.
Place the in the range you want to sort first and then the second and lastly
the third criteria. If you do so with a groupby option I think it should
reproduce what you are looking for.
 
G

Guest

I want to sort by Lt, then Asl, then Sec, then Shf but I want to keep like
containers together.
You do not have a field named 'containers' unless you mean 'case'.

But the last three are in the wrong position.

I do not get what is is not working. Please explain a little more.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top