Solr alphabetical sorting trouble. Sorting uppercase then lowercase for string type field
Posted
by
Alauddin Ansari
on Stack Overflow
See other posts from Stack Overflow
or by Alauddin Ansari
Published on 2013-10-25T09:51:27Z
Indexed on
2013/10/25
9:54 UTC
Read the original article
Hit count: 123
I've crated a title field with list below:
- Asking is good
- But answering is best
- join the group like this
- You are the best
- hey dudes. whass up
When I'm sorting this ASC (&sort=title ASC)
- Asking is good
- But answering is best
- You are the best
- hey dudes. whass up
- join the group like this
and (&sort=title DESC)
- join the group like this
- hey dudes. whass up
- You are the best
- But answering is best
- Asking is good
But I'm expecting result like: (&sort=title ASC)
- Asking is good
- But answering is best
- hey dudes. whass up
- join the group like this
- You are the best
schema.xml
<field name="title" type="text_general" indexed="true" stored="true"/>
<field name="title_sort" type="string" indexed="true" stored="false"/>
<copyField source="title" dest="title_sort" />
I'm using title_sort field to sort (also tried title field)
Please tell me where I'm going wrong
© Stack Overflow or respective owner