lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joey <joey...@hotmail.com>
Subject Re: Special character in a field used by sort parameter
Date Thu, 26 May 2011 01:24:26 GMT
Marc SCHNEIDER <marc.schneider73 <at> gmail.com> writes:

> 
> Hi,
> 
> I have a field called test-id but I can't use it when sorting, for example :
> Doesn't work : ("undefined field test")
> http://localhost:8180/solr/test-public/select/?q=test-id:1&sort=test-id+asc
> http://localhost:8180/solr/test-public/select/?q=test-id:1&sort=test\-id+asc
> 
> When removing the sort parameter then it works...
> 
> Is there a way of escaping the field name in sort parameter?
> 
> Thanks in advance,
> Marc.
> 


I've also got a similar issue. When the field name has a hyphen and the first
character is alphabetical, upon sorting solr says my field is undefined. 

a) It sorts fine when the first character is numerical, and
b) I've tried encoding the url but hyphens don't encode.

If anyone has a fix, I would be stoked to hear it.

J


Mime
View raw message