Sort order in Windows Explorer

Posted by Haim H. on Super User See other posts from Super User or by Haim H.
Published on 2012-04-23T11:52:33Z Indexed on 2012/09/06 15:41 UTC
Read the original article Hit count: 485

The behaviour described below occurs on Windows-7 systems and on Windows XP. We operate in a dual-language environment - English and Hebrew.

When in Windows Explorer we sort files by name, the order in which they are listed is not what we would expect. Here is a list of file names as sorted by Windows Explorer (all of the files have a .pdf suffix):

1G110033H-PP
19C050G-PP-ORB
19C050H-PPRM
19C100H-PPRM
19C-MBPS-PP
19C-MBPS-PP-1
29AAC050-PP
29AAC100-PP
29AAC100-PPUL  
29B004064-PP
101AC050-PP
101AC100-PP
101B100-PPE
1091003G-PPFSUL
10108033G-PPSA
10125033H-PPM

enter image description here

It looks to me that first the items are sorted according to the position of the first alphabetic character in the name, and then, within those groups, they are sorted in "normal" alpha-numeric order.

That is, all the files with an alpha character in the first position are on top of the list, followed by those with the first alpha character in the second position, followed by those with the first alpha character in the third position, and so on.

An alternate way of looking at this is that, in a file name composed of numbers and letters, the sort treats the first group of numbers in the name as the major sort node, with the rest of the name being the secondary sort node.

Now that I understand the sequencing logic, it's not a big problem, but I was wondering why this happens?

© Super User or respective owner

Related posts about windows-7

Related posts about Windows