Thank you Robi. Your idea seems good but I have a few questions: 

1.      From your description, I would create a field “Function_s” with the 
value
“Scanner” and “Function_s” with the value “Printer” for my two Products.
This seems good. Is it possible for you give me a query for this dynamic
field. For e.g., could I do something like: 

&facet=true&facet.field=Function_s

I would like this to tell me how many of the products are Scanners and how
many of the products are Printers.

2.      Many of my Attribute Names have spaces e.g. “PC Connection”, or even
brackets and slashes e.g. “Scan Speed (ppm)”. Would there be a problem
putting these in a dynamic field name?

3.      Is it possible to query for the possible list of dynamic fieldnames? I
might need this when creating a list of attributes.


Thanks again Robi.
O. O.

----------------------------------------------

Petersen, Robert wrote
> Hi O.O.,
> 
> You don't need to add them all into the schema.  You can use the wildcard
> fields like 
> <dynamicField name="*_s"  type="string"  indexed="true"  stored="true" />
>  to hold them.  You can then have the attribute name be the part of the
> wildcard and the attribute value be the field contents. So you could have
> fields like Function_s:Scanner etc and then you could ask for facets which
> are relevant based upon query or category.
> 
> That would be a much more straightforward approach and much easier to
> facet on.  Hope that helps a little bit.
> 
> -Robi





--
View this message in context: 
http://lucene.472066.n3.nabble.com/Solr-Faceting-with-Name-Values-tp4036872p4036904.html
Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to