Re: Numeric fields and payload

2013-09-05 Thread Erick Erickson
Peter:

I don't quite get this. Formatting to display is trivial as it's
usually done for just a few docs anyway. You could also
just store the original unaltered value and add an additional
normalized field.

Best
Erick


On Wed, Sep 4, 2013 at 2:02 PM, PETER LENAHAN peter_lena...@ibi.com wrote:

 Chris Hostetter hossman_lucene at fucit.org writes:

 
 
  : is it possible to store (text) payload to numeric fields (class
  : solr.TrieDoubleField)?  My goal is to store measure units to numeric
  : features - e.g. '1.5 cm' - and to use faceted search with these fields.
  : But the field type doesn't allow analyzers to add the payload data. I
  : want to avoid database access to load the units. I'm using Solr 4.2 .
 
  I'm not sure if it's possible to add payloads to Trie fields, but even if
  there is i don't think you really want that for your usecase -- i think
 it
  would make a lot more sense to normalize your units so you do consistent
  sorting, range queries, and faceting on the values regardless of wether
  it's 100cm or 1000mm or 1m.
 
  -Hoss
 
 

 Hoss,  What you suggest may be fine for specific units. But for monetary
 values with formatting it is not realistic. $10,000.00 would require
 formatting the number to display it.  It would be much easier to store the
 string as a payload with the formatted value.


 Peter Lenahan




Re: Numeric fields and payload

2013-09-04 Thread PETER LENAHAN
Chris Hostetter hossman_lucene at fucit.org writes:

 
 
 : is it possible to store (text) payload to numeric fields (class 
 : solr.TrieDoubleField)?  My goal is to store measure units to numeric 
 : features - e.g. '1.5 cm' - and to use faceted search with these fields. 
 : But the field type doesn't allow analyzers to add the payload data. I 
 : want to avoid database access to load the units. I'm using Solr 4.2 .
 
 I'm not sure if it's possible to add payloads to Trie fields, but even if 
 there is i don't think you really want that for your usecase -- i think it 
 would make a lot more sense to normalize your units so you do consistent 
 sorting, range queries, and faceting on the values regardless of wether 
 it's 100cm or 1000mm or 1m.
 
 -Hoss
 
 

Hoss,  What you suggest may be fine for specific units. But for monetary 
values with formatting it is not realistic. $10,000.00 would require 
formatting the number to display it.  It would be much easier to store the 
string as a payload with the formatted value.


Peter Lenahan



Re: Numeric fields and payload

2013-05-08 Thread Chris Hostetter

: is it possible to store (text) payload to numeric fields (class 
: solr.TrieDoubleField)?  My goal is to store measure units to numeric 
: features - e.g. '1.5 cm' - and to use faceted search with these fields. 
: But the field type doesn't allow analyzers to add the payload data. I 
: want to avoid database access to load the units. I'm using Solr 4.2 .

I'm not sure if it's possible to add payloads to Trie fields, but even if 
there is i don't think you really want that for your usecase -- i think it 
would make a lot more sense to normalize your units so you do consistent 
sorting, range queries, and faceting on the values regardless of wether 
it's 100cm or 1000mm or 1m.


-Hoss


Numeric fields and payload

2013-04-08 Thread Holger Rieß
Hi,

is it possible to store (text) payload to numeric fields (class 
solr.TrieDoubleField)?  My goal is to store measure units to numeric features - 
e.g. '1.5 cm' -  and to use faceted search with these fields. But the field 
type doesn't allow analyzers to add the payload data. I want to avoid database 
access to load the units. I'm using Solr 4.2 .

Regards,
Holger


Re: Numeric fields and payload

2013-04-08 Thread Jack Krupansky
Sounds like another new field-mutating update processor is needed - add 
payload.


-- Jack Krupansky

-Original Message- 
From: Holger Rieß

Sent: Monday, April 08, 2013 8:27 AM
To: solr-user@lucene.apache.org
Subject: Numeric fields and payload

Hi,

is it possible to store (text) payload to numeric fields (class 
solr.TrieDoubleField)?  My goal is to store measure units to numeric 
features - e.g. '1.5 cm' -  and to use faceted search with these fields. But 
the field type doesn't allow analyzers to add the payload data. I want to 
avoid database access to load the units. I'm using Solr 4.2 .


Regards,
Holger