On a quick glance: You're trying to sort on a tokenized field, which is not good. Not good at all. You'll go 'round and 'round and it'll never give you what you want.
Consider your example "Whithers, Alfred Robert" The WhitespaceTokenizer breaks this up into three tokens (I'm ignoring everything but whitespace and lowercase) "whithers", "alfred" and "robert" and puts these tokens in the index. What does sorting on this field mean? Should this be put in Ws? As? Rs? The usual process is to use copyfield and put the input into an un-tokenized field and sort on that field. The stock schema.xml comes with an "alphaOnlySort" that should be a good place to start Best Erick On Wed, Nov 17, 2010 at 11:15 PM, Scott Yeadon <scott.yea...@anu.edu.au>wrote: > Sorry, looks like it was a data-related issue, apologies for the noise > (although if anyone spots anything dodgy in the config feel free to let me > know). > > Scott. > > > On 18/11/10 2:21 PM, Scott Yeadon wrote: > >> Hi, >> >> I'm running solr-tomcat 1.4.0 on Ubuntu and have an issue with the sorting >> of results. According to this page >> http://web.archiveorange.com/archive/v/AAfXfzy5Tm1uDy5mYW3B I should be >> able to configure the LowerCaseFilterFactory to ensure results will be >> indexed and returned in a case insensitive means, however this does not >> appear to be working for me. Is someone able to check my field config to >> confirm it is ok (and if anyone has any advice on making this work it would >> be appreciated - my issue is the same as that in the provided link (that is, >> upper case and lower case are being ordered separately instead of being >> interspersed). The sort field I'm using is of type text as defined below. >> >> The text field type is configured as follows: >> >> <fieldType name="text" class="solr.TextField" positionIncrementGap="100"> >> <analyzer type="index"> >> <tokenizer class="solr.WhitespaceTokenizerFactory"/> >> <filter class="solr.StopFilterFactory" >> ignoreCase="true" >> words="stopwords.txt" >> enablePositionIncrements="true" >> /> >> <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" >> generateNumberParts="1" catenateWords="1" catenateNumbers="1" >> catenateAll="0" splitOnCaseChange="1"/> >> <filter class="solr.LowerCaseFilterFactory"/> >> <filter class="solr.SnowballPorterFilterFactory" language="English" >> protected="protwords.txt"/> >> </analyzer> >> <analyzer type="query"> >> <tokenizer class="solr.WhitespaceTokenizerFactory"/> >> <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" >> ignoreCase="true" expand="true"/> >> <filter class="solr.StopFilterFactory" >> ignoreCase="true" >> words="stopwords.txt" >> enablePositionIncrements="true" >> /> >> <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" >> generateNumberParts="1" catenateWords="0" catenateNumbers="0" >> catenateAll="0" splitOnCaseChange="1"/> >> <filter class="solr.LowerCaseFilterFactory"/> >> <filter class="solr.SnowballPorterFilterFactory" language="English" >> protected="protwords.txt"/> >> </analyzer> >> </fieldType> >> >> When I sort on a primaryName field (which is a "text" field as define >> above) for example, I get records listed out of order as in the following >> example: >> - Withers, Alfred Robert (1863–1956) >> - Young, Charles (1838–1916) >> - de Little, Ernest (1868–1926) >> - de Pledge, Thomas Frederick (1867–1954) >> - von Bibra, William (1876–1926) >> >> I imagine I'm missing something obvious, the obvious workaround is a >> namesort field however from the above post it looks like this can be >> avoided. >> >> Scott. >> >> >> >