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 Mikhail Khludnev <mk...@griddynamics.com> on 2014/12/10 21:02:57 UTC
Re: Question regarding Solr 4.7 solr joining across multiple cores
and sorting
https://issues.apache.org/jira/browse/SOLR-6234
{!scorejoin} which is a Solr QParser brings Lucene JoinUtil, for sure.
replying into appropriate list.
On Wed, Dec 10, 2014 at 10:14 PM, Parnit Pooni <pa...@gmail.com> wrote:
> Hi,
> I'm running into an issue attempting to sort, here is the scenario.
>
> I have my mainIndex which looks something like this.
>
> id description name
> 1 "description1 " "name1"
> 2 "description2 " "name2"
>
> I also have a subIndex which looks something like this
>
> id metric
> 1 4
> 2 5
>
> What I am trying to do is join the two index's on the id column and have
> my results sorted based on a column from the subIndex with a query like the
> following.
>
> testServer/solr/MainIndex/select?defType=edismax&q=*&fq={!join from=id to=id fromIndex=subIndex}id:*&sort=metric desc
>
> desired result
>
> 2 "description2 " "name2"
> 1 "description1 " "name1"
>
> I'm aware that you lose all information from the subIndex the moment the
> parser sees "&". What are my options should I want to join two indexes and
> sort on a column not present in the main index?
>
> Thanks in advance.
> Parnit
>
>
--
Sincerely yours
Mikhail Khludnev
Principal Engineer,
Grid Dynamics
<http://www.griddynamics.com>
<mk...@griddynamics.com>