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: How to get the join data by multiple cores?
Date Thu, 22 Oct 2015 20:47:23 GMT
Mikhail:

Brilliant! Assuming we can get the "from" and "to" parameters out of
the query and, perhaps, the fromIndex (for cross-core) then it
_should_ just be a matter of fetching the from doc and adding the
fields. And since it's only operating on the returned documents it
also shouldn't be very expensive in the case of the "usual" 10-20
document retrieval sets.

I can see it slowing things down very considerably for large result
sets, but those can be slow currently anyway.

Not sure how to specify the fields that should come from the "from"
document, but that's a tractable problem. Perhaps a different (local?)
param (fl_from or some such?).

Sounds like a JIRA to me...

On Thu, Oct 22, 2015 at 1:12 PM, Mikhail Khludnev
<mkhludnev@griddynamics.com> wrote:
> thread hijack:
> Erick, wdyt about writing query-time analog of [child]
> https://cwiki.apache.org/confluence/display/solr/Transforming+Result+Documents
> ?
>
>
> On Thu, Oct 22, 2015 at 6:32 PM, Erick Erickson <erickerickson@gmail.com>
> wrote:
>>
>> You will NOT get the stored fields from the child record
>> with the join operation, it's called "pseudo join" for a
>> good reason.
>>
>> It's usually a mistake to try to force Solr to performa just
>> like a database. I would seriously consider flattening
>> (denormalizing) the data if at all possible.
>>
>> Best,
>> Erick
>>
>> On Wed, Oct 21, 2015 at 10:36 PM, cai xingliang <caixingliang@gmail.com>
>> wrote:
>> > {!join fromIndex=parent from=id to=parent_id}tag:hoge
>> >
>> > That should work.
>> > On Oct 22, 2015 12:35 PM, "Shuhei Suzuki" <hum2.dmg@gmail.com> wrote:
>> >
>> >> hello,
>> >> What can I do to throw a query such as the following in Solr?
>> >>
>> >>  SELECT
>> >>   child. *, parent. *
>> >>  FROM child
>> >>  JOIN parent
>> >>  WHERE child.parent_id = parent.id AND parent.tag = 'hoge'`
>> >>
>> >> child and parent is not that parent is more than in a many-to-one
>> >> relationship.
>> >> I try this but can not.
>> >>
>> >>  /select/?q={!join from=parent_id to=id fromIndex=parent}id:1+tag:hoge
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> >> http://lucene.472066.n3.nabble.com/How-to-get-the-join-data-by-multiple-cores-tp4235799.html
>> >> Sent from the Solr - User mailing list archive at Nabble.com.
>> >>
>
>
>
>
> --
> Sincerely yours
> Mikhail Khludnev
> Principal Engineer,
> Grid Dynamics
>
>

Mime
View raw message