I had a similar issue with a heavy use of dynamic fields. You first want to get those spaces out of there. Lucene does not like spaces in field names. So, I just replaced the space with a rarely used character (ASCII 8 or something like that). I did this in my indexing. And then I just translate between the Lucene encoded field name (without spaces) and my display field name (with spaces) when I go back and forth between Solr and my client.
So, your "Download Speed"=>"DownloadSpeed"=>"Download Speed". Spaces are the only characters that seemed to cause problems. It seems to work just fine. ----- Original Message ---- From: Will Johnson <[EMAIL PROTECTED]> To: solr-user@lucene.apache.org Sent: Friday, May 25, 2007 1:48:22 PM Subject: RE: field display values I would normally agree but the problem is that I'm making very heavy use of the dynamic fields and therefore don't really know what a record looks like. Ie the only thing that knows about the data is the input data itself. I've added logic to 'solrify' the input field names as they come to me in the "Download Speed" format but making the reverse happen is impossible from the client side because each record is different. - will -----Original Message----- From: Ryan McKinley [mailto:[EMAIL PROTECTED] Sent: Friday, May 25, 2007 4:32 PM To: solr-user@lucene.apache.org Subject: Re: field display values Will Johnson wrote: > Has anyone done anything interesting to preserve display values for > field names. Ie my users would like to see > > Download Speed (MB/sec): 5 > > As opposed to: > > ds:5 > > The general model has been to think of solr like SQL... it is only the database - display choices should be at the client side. It seems easy enough to have a map on the client with: "ds" => "Download Speed (MB/sec)" That said, something like the sql 'as' command would be useful: SELECT ds as `Download Speed (MB/sec)` FROM table...; rather then define the field name at index time (as your example suggests) it makes more sense to define it at query time (or as a default in the RequestHandler config) Maybe something like: /select?fl=ds&display.ds=Download Speed (MB/sec) Maybe this would be a way to specify date formatting? /select?fl=timestamp&display.timestamp='Year'&display.format.timestamp=Y YYY just thoughts...