Sorting of file names in Explorer

R

Robert M. Lincoln

The files I have displayed in the Explorer window (view option set -
details) are not sorted according to how I would expect them to be sorted.
The list below shows the sorting of the Name field. The ASCII code for a
hyphen is before letters. Why are the filenames not sorted in ascending
alphabetical order? Does the hyphen mess things up?

For example, the last entry, "ft-tj-Solomon.html" should occur much higher
in the list, after "ft-tj-Peter2.html". Why doesn't it?

ft-tj-Caleb.html
ft-tj-Deborah.html
ft-tj-Isaac.html
ft-tj-Jacob1.html
ft-tj-Jacob2.html
ft-tj-Joshua.html
ft-tj-Margaret.html
ft-tj-Peter1.html
ft-tj-Peter2.html
ft-tjsij-John.html
ft-tjsijj-Warren.html
ft-tjsijjwra-Irene.html
ft-tjsijjwr-Allan.html
ft-tjsijjwra-Lola.html
ft-tjsijjwra-Louise.html
ft-tjsijjwra-Robert.html
ft-tjsijjwre-Frankie.html
ft-tjsijjwr-Elery.html
ft-tjsijjw-Robert.html
ft-tjsi-John.html
ft-tjs-Isaac.html
ft-tj-Solomon.html


Thanks,

Bob
 
P

Peter W.

Robert M. Lincoln said:
The files I have displayed in the Explorer window (view option set -
details) are not sorted according to how I would expect them to be sorted.
The list below shows the sorting of the Name field. The ASCII code for a
hyphen is before letters. Why are the filenames not sorted in ascending
alphabetical order? Does the hyphen mess things up?

For example, the last entry, "ft-tj-Solomon.html" should occur much higher
in the list, after "ft-tj-Peter2.html". Why doesn't it?

ft-tj-Caleb.html
ft-tj-Deborah.html
ft-tj-Isaac.html
ft-tj-Jacob1.html
ft-tj-Jacob2.html
ft-tj-Joshua.html
ft-tj-Margaret.html
ft-tj-Peter1.html
ft-tj-Peter2.html
ft-tjsij-John.html
ft-tjsijj-Warren.html
ft-tjsijjwra-Irene.html
ft-tjsijjwr-Allan.html
ft-tjsijjwra-Lola.html
ft-tjsijjwra-Louise.html
ft-tjsijjwra-Robert.html
ft-tjsijjwre-Frankie.html
ft-tjsijjwr-Elery.html
ft-tjsijjw-Robert.html
ft-tjsi-John.html
ft-tjs-Isaac.html
ft-tj-Solomon.html


Thanks,

Bob

no, fttjso simply follows fttjsi
 
G

Gene E. Bloch

The files I have displayed in the Explorer window (view option set -
details) are not sorted according to how I would expect them to be sorted.
The list below shows the sorting of the Name field. The ASCII code for a
hyphen is before letters. Why are the filenames not sorted in ascending
alphabetical order? Does the hyphen mess things up?

For example, the last entry, "ft-tj-Solomon.html" should occur much higher
in the list, after "ft-tj-Peter2.html". Why doesn't it?

ft-tj-Caleb.html
ft-tj-Deborah.html
ft-tj-Isaac.html
ft-tj-Jacob1.html
ft-tj-Jacob2.html
ft-tj-Joshua.html
ft-tj-Margaret.html
ft-tj-Peter1.html
ft-tj-Peter2.html
ft-tjsij-John.html
ft-tjsijj-Warren.html
ft-tjsijjwra-Irene.html
ft-tjsijjwr-Allan.html
ft-tjsijjwra-Lola.html
ft-tjsijjwra-Louise.html
ft-tjsijjwra-Robert.html
ft-tjsijjwre-Frankie.html
ft-tjsijjwr-Elery.html
ft-tjsijjw-Robert.html
ft-tjsi-John.html
ft-tjs-Isaac.html
ft-tj-Solomon.html


Thanks,

Bob

I was trying to figure out what Peter W. was saying. It looks like he is
suggesting that the sorting ignores the hyphens.

Geez - do I have to create a directory of such names now to experiment?
Such a pain :)

Well, I did - it take very long - and I verified that hyphens are ignored.

1. My folder ended up sorted just like your list.

2. When I inserted hyphens *anywhere* in a filename it didn't change its
location in the list. Commas, equal signs, and dots did alter the location.

OK, there might be a setting somewhere to change this, but I have no idea
where.
 
R

Robert M. Lincoln

I think "sometimes" the hyphen is ignored. For example, in my list (part of
which is shown below), if you ignored hyphens, "ft-tjsijjwr-Allan.html"
should be the first in the list, as "A" should come before "a". So, it's
not at all predictable.

ft-tjsijjwra-Irene.html
ft-tjsijjwr-Allan.html
ft-tjsijjwra-Lola.html
ft-tjsijjwra-Louise.html
ft-tjsijjwra-Robert.html

I heard from someone that Microsoft, in the "compare strings" routine,
assigns "weights" to some symbols to yield results that are "culturally
expected". I think to avoid confusion, it is just better to avoid hypens in
file names.

Thanks,

Bob Lincoln



----- Original Message -----
From: "Gene E. Bloch" <[email protected]>
Newsgroups: microsoft.public.windows.vista.general
Sent: Tuesday, July 13, 2010 3:40 PM
Subject: Re: Sorting of file names in Explorer
 
Top