lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <erickerick...@gmail.com>
Subject Re: Hierarchical faceting with solr 1.4 version
Date Thu, 02 Feb 2012 00:42:24 GMT
Well, a lot depends on how you need to query. The simplest
would be to store triplets MSA/Area/Hood, that is denormalize
the data and store each. If you used a multiValued field to store
it, you could do some tricky dancing with positionIncrementGap
to insure that matches occurred as you wish.

But if that doesn't make sense, perhaps you could expand on
the kinds of queries that need to happen.

Best
Erick

On Wed, Feb 1, 2012 at 12:58 AM, Gupta, Veeranjaneya
<Veeranjaneya.Gupta@travelocity.com> wrote:
> Hi,
>
> I am using SOLR1.4 version. I have a requirement to display the data as below.
>
> <Polygon id="TX172-0000" type="MSA" name="Dallas/Ft. Worth" dictionaryId="297224">
> <Polygon id="TX172-0200" type="Area" name="Denton" dictionaryId="296635"/>
> <Polygon id="TX172-1000" type="Area" name="Grand Prairie" dictionaryId="400702">
> <Polygon id="TX172-0601" type="Hood" name="Entertainment District" dictionaryId="14993"/>
> <Polygon id="TX172-0404" type="Hood" name="South Dallas" dictionaryId="279265"/>
> </Polygon>
> <Polygon id="TX172-0800" type="Area" name="Northeast Dallas" dictionaryId="297286">
> <Polygon id="TX172-0809" type="Hood" name="Park Central" dictionaryId="15424"/>
> <Polygon id="TX172-0808" type="Hood" name="Addison" dictionaryId="15384"/>
> <Polygon id="TX172-0807" type="Hood" name="Galleria" dictionaryId="15417"/>
> </Polygon>
> <Polygon id="TX172-0300" type="Area" name="Fort Worth" dictionaryId="296683">
> <Polygon id="TX172-0305" type="Hood" name="TCU and Forest Park" dictionaryId="279770"/>
> <Polygon id="TX172-0303" type="Hood" name="North Fort Worth and Fossil Creek" dictionaryId="278905"/>
> <Polygon id="TX172-0302" type="Hood" name="Alliance and Texas Motor Speedway" dictionaryId="296856"/>
> </Polygon>
> </Polygon>
>
> Here we store 3 types of polygons MSA, AREA and HOOD.
> One MSA can have more than one AREA types as children and one AREA can have more than
one HOOD types as children.
> How to store this kind of data in solr and how to query the solr to get this hierarchical
data?
>
> Thanks, Gupta

Mime
View raw message