: business needs.  Our problem is that we have a catalog schema with 
: products and skus, one to many.  The most relevant content being indexed 
: is at the product level, in the name and description fields.  However we 
: are interested in filtering by sku attributes, and in particular making 
: multiple filters apply to a single sku.  For example, find a product 

the first rule of denormalization is to construct documents bsaed on what 
you granularity you wnat to get back -- because from a user perspective, 
that level of granularity is whta's going to make sense for 
faceting/filtern.  

If you want your results to be product based have one doc per product -- 
if you results to be sku based, have one doc per sku, and denormalize the 
product data redundently into every sku.

if sometimes you wnat to reutnr product data, and other times you wnat to 
return sku data, then create both types of documents (either in different 
indexes, or in the same index but with a doctype field that you can filter 
on)



-Hoss

Reply via email to