You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by hkmortensen <ko...@yahoo.com> on 2010/05/19 17:04:26 UTC

Re: Challenge: Searching for variant products and get basic products in result set

thanks. Currently not, but requirements change all the time as always ;-) 
If we get a requirement, that a facet shall be "material of doors", we will
need to know which variant was the hit. I would like to be prepared for
that.




Leonardo Menezes wrote:
> 
> would you then need to know in which variant was your match produced?
> because if not, you can just index the whole thing as one single
> document...
> 
> On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
> 
>>
>> I do searching for products. Each base product exist in variants as well.
>> One
>> variant has a glass door, another a steel door etc. The variants can have
>> diffent prices. The base product does not really exist, only the variants
>> exists IRL. The case corresponds to cars: the car model is the base
>> product,
>> with color variants  or with automatic/manual etc.
>>
>> I want to search for variants, but I only want to have base products in
>> the
>> result. Ie when one or more variants from the same base product are
>> found,
>> only the base product shall be in the search result.
>>
>> Does somebody have an idea how this could be done?
>>
>> Best regards
>>
>> Henning
>> --
>> View this message in context:
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> 

-- 
View this message in context: http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Challenge: Searching for variant products and get basic products in result set

Posted by hkmortensen <ko...@yahoo.com>.
your are right, in that case an arbitrary on would have to be chosen or
probably then both should be in the result set. Difficult to say what the
marketing department would like ;-)



Leonardo Menezes wrote:
> 
> if that is so, and maybe, you have for example, two variants of cars with
> automatic, what would define on which one was the hit? or field dont share
> common information across variants? if they do share, you wouldnt be able
> to
> define in which one was the hit(because it was on both of them) and would
> either have to pick one randomly, or retrieve both. if they dont share
> that
> info, you would have that covered, since only one would match any given
> query.
> 
> On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:
> 
>>
>> thanks. Currently not, but requirements change all the time as always ;-)
>> If we get a requirement, that a facet shall be "material of doors", we
>> will
>> need to know which variant was the hit. I would like to be prepared for
>> that.
>>
>>
>>
>>
>> Leonardo Menezes wrote:
>> >
>> > would you then need to know in which variant was your match produced?
>> > because if not, you can just index the whole thing as one single
>> > document...
>> >
>> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
>> >
>> >>
>> >> I do searching for products. Each base product exist in variants as
>> well.
>> >> One
>> >> variant has a glass door, another a steel door etc. The variants can
>> have
>> >> diffent prices. The base product does not really exist, only the
>> variants
>> >> exists IRL. The case corresponds to cars: the car model is the base
>> >> product,
>> >> with color variants  or with automatic/manual etc.
>> >>
>> >> I want to search for variants, but I only want to have base products
>> in
>> >> the
>> >> result. Ie when one or more variants from the same base product are
>> >> found,
>> >> only the base product shall be in the search result.
>> >>
>> >> Does somebody have an idea how this could be done?
>> >>
>> >> Best regards
>> >>
>> >> Henning
>> >> --
>> >> View this message in context:
>> >>
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
>> >> Sent from the Solr - User mailing list archive at Nabble.com.
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> 

-- 
View this message in context: http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829413.html
Sent from the Solr - User mailing list archive at Nabble.com.

RE: Challenge: Searching for variant products and get basic products in result set

Posted by hkmortensen <ko...@yahoo.com>.
yes I think that will make a good solution. In Dänish "sku" is a bad word
;-), but thanks for the info.


Nagelberg, Kallin wrote:
> 
> Sorry, in North America 'sku' (stock keeping unit) is the common term in
> business to specifically identify a particular product,
> http://lmgtfy.com/?q=sku. 
> 
> And yes, I think you understand me. I am imagining you can structure your
> products in a hierarchy. For each node in the tree you traverse all
> children, collecting their attributes into the current node.
> 
> -Kallin Nagelberg
> 
> -----Original Message-----
> From: hkmortensen [mailto:kokdk@yahoo.com] 
> Sent: Wednesday, May 19, 2010 11:39 AM
> To: solr-user@lucene.apache.org
> Subject: RE: Challenge: Searching for variant products and get basic
> products in result set
> 
> 
> sorry, what does "sku" mean?
> 
> I understand you like this: indexing base and variants, and include all
> atributes (for one base and its variants) in each document. I think that
> would work. Thanks.
> 
> 
> Nagelberg, Kallin wrote:
>> 
>> I agree that pulling all attributes into the parent sku during indexing
>> could work well. Define a Boolean field like 'isVirtual' to identify the
>> non-leaf skus, and use a multi-valued field for each of the attributes.
>> For now you can do a search like (isVirtual:true AND doorType:screen). If
>> at a later date you want the actual variants just search for
>> isVirtual:false.
>> 
>> Does that work?
>> 
>> -Kallin Nagelberg
>> 
>> -----Original Message-----
>> From: Leonardo Menezes [mailto:leonardo.menezess@googlemail.com] 
>> Sent: Wednesday, May 19, 2010 11:13 AM
>> To: solr-user@lucene.apache.org
>> Subject: Re: Challenge: Searching for variant products and get basic
>> products in result set
>> 
>> if that is so, and maybe, you have for example, two variants of cars with
>> automatic, what would define on which one was the hit? or field dont
>> share
>> common information across variants? if they do share, you wouldnt be able
>> to
>> define in which one was the hit(because it was on both of them) and would
>> either have to pick one randomly, or retrieve both. if they dont share
>> that
>> info, you would have that covered, since only one would match any given
>> query.
>> 
>> On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:
>> 
>>>
>>> thanks. Currently not, but requirements change all the time as always
>>> ;-)
>>> If we get a requirement, that a facet shall be "material of doors", we
>>> will
>>> need to know which variant was the hit. I would like to be prepared for
>>> that.
>>>
>>>
>>>
>>>
>>> Leonardo Menezes wrote:
>>> >
>>> > would you then need to know in which variant was your match produced?
>>> > because if not, you can just index the whole thing as one single
>>> > document...
>>> >
>>> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
>>> >
>>> >>
>>> >> I do searching for products. Each base product exist in variants as
>>> well.
>>> >> One
>>> >> variant has a glass door, another a steel door etc. The variants can
>>> have
>>> >> diffent prices. The base product does not really exist, only the
>>> variants
>>> >> exists IRL. The case corresponds to cars: the car model is the base
>>> >> product,
>>> >> with color variants  or with automatic/manual etc.
>>> >>
>>> >> I want to search for variants, but I only want to have base products
>>> in
>>> >> the
>>> >> result. Ie when one or more variants from the same base product are
>>> >> found,
>>> >> only the base product shall be in the search result.
>>> >>
>>> >> Does somebody have an idea how this could be done?
>>> >>
>>> >> Best regards
>>> >>
>>> >> Henning
>>> >> --
>>> >> View this message in context:
>>> >>
>>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
>>> >> Sent from the Solr - User mailing list archive at Nabble.com.
>>> >>
>>> >
>>> >
>>>
>>> --
>>> View this message in context:
>>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>> 
>> 
> 
> -- 
> View this message in context:
> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829435.html
> Sent from the Solr - User mailing list archive at Nabble.com.
> 
> 

-- 
View this message in context: http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829530.html
Sent from the Solr - User mailing list archive at Nabble.com.

RE: Challenge: Searching for variant products and get basic products in result set

Posted by "Nagelberg, Kallin" <KN...@globeandmail.com>.
Sorry, in North America 'sku' (stock keeping unit) is the common term in business to specifically identify a particular product, http://lmgtfy.com/?q=sku. 

And yes, I think you understand me. I am imagining you can structure your products in a hierarchy. For each node in the tree you traverse all children, collecting their attributes into the current node.

-Kallin Nagelberg

-----Original Message-----
From: hkmortensen [mailto:kokdk@yahoo.com] 
Sent: Wednesday, May 19, 2010 11:39 AM
To: solr-user@lucene.apache.org
Subject: RE: Challenge: Searching for variant products and get basic products in result set


sorry, what does "sku" mean?

I understand you like this: indexing base and variants, and include all
atributes (for one base and its variants) in each document. I think that
would work. Thanks.


Nagelberg, Kallin wrote:
> 
> I agree that pulling all attributes into the parent sku during indexing
> could work well. Define a Boolean field like 'isVirtual' to identify the
> non-leaf skus, and use a multi-valued field for each of the attributes.
> For now you can do a search like (isVirtual:true AND doorType:screen). If
> at a later date you want the actual variants just search for
> isVirtual:false.
> 
> Does that work?
> 
> -Kallin Nagelberg
> 
> -----Original Message-----
> From: Leonardo Menezes [mailto:leonardo.menezess@googlemail.com] 
> Sent: Wednesday, May 19, 2010 11:13 AM
> To: solr-user@lucene.apache.org
> Subject: Re: Challenge: Searching for variant products and get basic
> products in result set
> 
> if that is so, and maybe, you have for example, two variants of cars with
> automatic, what would define on which one was the hit? or field dont share
> common information across variants? if they do share, you wouldnt be able
> to
> define in which one was the hit(because it was on both of them) and would
> either have to pick one randomly, or retrieve both. if they dont share
> that
> info, you would have that covered, since only one would match any given
> query.
> 
> On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:
> 
>>
>> thanks. Currently not, but requirements change all the time as always ;-)
>> If we get a requirement, that a facet shall be "material of doors", we
>> will
>> need to know which variant was the hit. I would like to be prepared for
>> that.
>>
>>
>>
>>
>> Leonardo Menezes wrote:
>> >
>> > would you then need to know in which variant was your match produced?
>> > because if not, you can just index the whole thing as one single
>> > document...
>> >
>> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
>> >
>> >>
>> >> I do searching for products. Each base product exist in variants as
>> well.
>> >> One
>> >> variant has a glass door, another a steel door etc. The variants can
>> have
>> >> diffent prices. The base product does not really exist, only the
>> variants
>> >> exists IRL. The case corresponds to cars: the car model is the base
>> >> product,
>> >> with color variants  or with automatic/manual etc.
>> >>
>> >> I want to search for variants, but I only want to have base products
>> in
>> >> the
>> >> result. Ie when one or more variants from the same base product are
>> >> found,
>> >> only the base product shall be in the search result.
>> >>
>> >> Does somebody have an idea how this could be done?
>> >>
>> >> Best regards
>> >>
>> >> Henning
>> >> --
>> >> View this message in context:
>> >>
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
>> >> Sent from the Solr - User mailing list archive at Nabble.com.
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> 

-- 
View this message in context: http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829435.html
Sent from the Solr - User mailing list archive at Nabble.com.

RE: Challenge: Searching for variant products and get basic products in result set

Posted by hkmortensen <ko...@yahoo.com>.
sorry, what does "sku" mean?

I understand you like this: indexing base and variants, and include all
atributes (for one base and its variants) in each document. I think that
would work. Thanks.


Nagelberg, Kallin wrote:
> 
> I agree that pulling all attributes into the parent sku during indexing
> could work well. Define a Boolean field like 'isVirtual' to identify the
> non-leaf skus, and use a multi-valued field for each of the attributes.
> For now you can do a search like (isVirtual:true AND doorType:screen). If
> at a later date you want the actual variants just search for
> isVirtual:false.
> 
> Does that work?
> 
> -Kallin Nagelberg
> 
> -----Original Message-----
> From: Leonardo Menezes [mailto:leonardo.menezess@googlemail.com] 
> Sent: Wednesday, May 19, 2010 11:13 AM
> To: solr-user@lucene.apache.org
> Subject: Re: Challenge: Searching for variant products and get basic
> products in result set
> 
> if that is so, and maybe, you have for example, two variants of cars with
> automatic, what would define on which one was the hit? or field dont share
> common information across variants? if they do share, you wouldnt be able
> to
> define in which one was the hit(because it was on both of them) and would
> either have to pick one randomly, or retrieve both. if they dont share
> that
> info, you would have that covered, since only one would match any given
> query.
> 
> On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:
> 
>>
>> thanks. Currently not, but requirements change all the time as always ;-)
>> If we get a requirement, that a facet shall be "material of doors", we
>> will
>> need to know which variant was the hit. I would like to be prepared for
>> that.
>>
>>
>>
>>
>> Leonardo Menezes wrote:
>> >
>> > would you then need to know in which variant was your match produced?
>> > because if not, you can just index the whole thing as one single
>> > document...
>> >
>> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
>> >
>> >>
>> >> I do searching for products. Each base product exist in variants as
>> well.
>> >> One
>> >> variant has a glass door, another a steel door etc. The variants can
>> have
>> >> diffent prices. The base product does not really exist, only the
>> variants
>> >> exists IRL. The case corresponds to cars: the car model is the base
>> >> product,
>> >> with color variants  or with automatic/manual etc.
>> >>
>> >> I want to search for variants, but I only want to have base products
>> in
>> >> the
>> >> result. Ie when one or more variants from the same base product are
>> >> found,
>> >> only the base product shall be in the search result.
>> >>
>> >> Does somebody have an idea how this could be done?
>> >>
>> >> Best regards
>> >>
>> >> Henning
>> >> --
>> >> View this message in context:
>> >>
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
>> >> Sent from the Solr - User mailing list archive at Nabble.com.
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> 

-- 
View this message in context: http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829435.html
Sent from the Solr - User mailing list archive at Nabble.com.

RE: Challenge: Searching for variant products and get basic products in result set

Posted by "Nagelberg, Kallin" <KN...@globeandmail.com>.
I agree that pulling all attributes into the parent sku during indexing could work well. Define a Boolean field like 'isVirtual' to identify the non-leaf skus, and use a multi-valued field for each of the attributes. For now you can do a search like (isVirtual:true AND doorType:screen). If at a later date you want the actual variants just search for isVirtual:false.

Does that work?

-Kallin Nagelberg

-----Original Message-----
From: Leonardo Menezes [mailto:leonardo.menezess@googlemail.com] 
Sent: Wednesday, May 19, 2010 11:13 AM
To: solr-user@lucene.apache.org
Subject: Re: Challenge: Searching for variant products and get basic products in result set

if that is so, and maybe, you have for example, two variants of cars with
automatic, what would define on which one was the hit? or field dont share
common information across variants? if they do share, you wouldnt be able to
define in which one was the hit(because it was on both of them) and would
either have to pick one randomly, or retrieve both. if they dont share that
info, you would have that covered, since only one would match any given
query.

On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:

>
> thanks. Currently not, but requirements change all the time as always ;-)
> If we get a requirement, that a facet shall be "material of doors", we will
> need to know which variant was the hit. I would like to be prepared for
> that.
>
>
>
>
> Leonardo Menezes wrote:
> >
> > would you then need to know in which variant was your match produced?
> > because if not, you can just index the whole thing as one single
> > document...
> >
> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
> >
> >>
> >> I do searching for products. Each base product exist in variants as
> well.
> >> One
> >> variant has a glass door, another a steel door etc. The variants can
> have
> >> diffent prices. The base product does not really exist, only the
> variants
> >> exists IRL. The case corresponds to cars: the car model is the base
> >> product,
> >> with color variants  or with automatic/manual etc.
> >>
> >> I want to search for variants, but I only want to have base products in
> >> the
> >> result. Ie when one or more variants from the same base product are
> >> found,
> >> only the base product shall be in the search result.
> >>
> >> Does somebody have an idea how this could be done?
> >>
> >> Best regards
> >>
> >> Henning
> >> --
> >> View this message in context:
> >>
> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
> >> Sent from the Solr - User mailing list archive at Nabble.com.
> >>
> >
> >
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>

Re: Challenge: Searching for variant products and get basic products in result set

Posted by Leonardo Menezes <le...@googlemail.com>.
if that is so, and maybe, you have for example, two variants of cars with
automatic, what would define on which one was the hit? or field dont share
common information across variants? if they do share, you wouldnt be able to
define in which one was the hit(because it was on both of them) and would
either have to pick one randomly, or retrieve both. if they dont share that
info, you would have that covered, since only one would match any given
query.

On Wed, May 19, 2010 at 5:04 PM, hkmortensen <ko...@yahoo.com> wrote:

>
> thanks. Currently not, but requirements change all the time as always ;-)
> If we get a requirement, that a facet shall be "material of doors", we will
> need to know which variant was the hit. I would like to be prepared for
> that.
>
>
>
>
> Leonardo Menezes wrote:
> >
> > would you then need to know in which variant was your match produced?
> > because if not, you can just index the whole thing as one single
> > document...
> >
> > On Wed, May 19, 2010 at 4:23 PM, hkmortensen <ko...@yahoo.com> wrote:
> >
> >>
> >> I do searching for products. Each base product exist in variants as
> well.
> >> One
> >> variant has a glass door, another a steel door etc. The variants can
> have
> >> diffent prices. The base product does not really exist, only the
> variants
> >> exists IRL. The case corresponds to cars: the car model is the base
> >> product,
> >> with color variants  or with automatic/manual etc.
> >>
> >> I want to search for variants, but I only want to have base products in
> >> the
> >> result. Ie when one or more variants from the same base product are
> >> found,
> >> only the base product shall be in the search result.
> >>
> >> Does somebody have an idea how this could be done?
> >>
> >> Best regards
> >>
> >> Henning
> >> --
> >> View this message in context:
> >>
> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829218.html
> >> Sent from the Solr - User mailing list archive at Nabble.com.
> >>
> >
> >
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Challenge-Searching-for-variant-products-and-get-basic-products-in-result-set-tp829218p829319.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>