Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id A93F5200CA3 for ; Wed, 3 May 2017 07:20:12 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id A7C20160BAC; Wed, 3 May 2017 05:20:12 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id EC798160B9D for ; Wed, 3 May 2017 07:20:11 +0200 (CEST) Received: (qmail 65104 invoked by uid 500); 3 May 2017 05:20:10 -0000 Mailing-List: contact solr-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-user@lucene.apache.org Delivered-To: mailing list solr-user@lucene.apache.org Received: (qmail 65092 invoked by uid 99); 3 May 2017 05:20:09 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 May 2017 05:20:09 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 693C1C05A7 for ; Wed, 3 May 2017 05:20:09 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.88 X-Spam-Level: ** X-Spam-Status: No, score=2.88 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, KAM_LIVE=1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id 8sS_isO3aoQY for ; Wed, 3 May 2017 05:20:07 +0000 (UTC) Received: from mail-it0-f43.google.com (mail-it0-f43.google.com [209.85.214.43]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id BE9805F5CA for ; Wed, 3 May 2017 05:20:06 +0000 (UTC) Received: by mail-it0-f43.google.com with SMTP id o5so27250654ith.1 for ; Tue, 02 May 2017 22:20:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=+eK5pT2I7aDfqn0I6htWWxi7G4W1qWt0xP6gsZdCxzE=; b=HOjuwsrZ5R7fZWZTNYM48AYe/kRzmaf3I3AZcsuEUoaorslmeGi3byKs+jCbX90Tjz EGdqSk8pQCHDlW71YnS8tMNF57/dbtyRDab9fPRKSU7biqGjY6E2y+sEywHhp+tW0KuQ B9Mi2eZr0Luf50ptHBdDx0u87T9o+cWJU+Mn/I7IOWa+UhQ/VPEVqJTSs6RXdM8jNmT7 4ovmNaYj4cgTBBwuMs+tYVF/e7BwdNjvzqV7M9sANY21eUKfifu3az3ULeGcd4f7z4wu I33pDDw3/26Go9L2opGJauYJzin9ye6io0yXJ/g49VTnroTOGT1K1XknIJlzf4f0juIo mkjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=+eK5pT2I7aDfqn0I6htWWxi7G4W1qWt0xP6gsZdCxzE=; b=k2TZKVlNDhKWB0gdUSg8qjlXVkit98Gq0sTOScwPnfLbgTyKC0o8KYdL2NLZw43hNc 2yN4kFbdBj6gRu5jsm/N57/1I0NZAQSeBAwrTjjjoVB3vh7qmLlw+SGd1jEKftC7/iRp pPgLzK5kV6FSMsLPgRxX5fZuRABhDHc+5S4eLrvT/Knne1bH3vXgifjvUv7/0XX0Pe5h uij0bc50i/0oNQGcFWrQaKSOdpGN06sjl21nKfIbcz4DvJj+xNIoaaUJWaaD5grdpKZr wMb2gyMfOmufd9mJVGjDq5a3RpgK3jqacaSOO2vKLaNhY7QutsW0v5ULaHtzma5CxGdT K86w== X-Gm-Message-State: AN3rC/5nA1G/pXamkLUrjjDwwHpjJ+OghhUneWEqoxNAtPagZH1CkFU3 ZzcnkpBLHYCPLOS4q3nGRDBmZsV7Iw1w X-Received: by 10.36.69.225 with SMTP id c94mr6934243itd.79.1493788805411; Tue, 02 May 2017 22:20:05 -0700 (PDT) MIME-Version: 1.0 Received: by 10.79.89.133 with HTTP; Tue, 2 May 2017 22:20:05 -0700 (PDT) In-Reply-To: References: From: Zheng Lin Edwin Yeo Date: Wed, 3 May 2017 13:20:05 +0800 Message-ID: Subject: Re: Joining more than 2 collections To: solr-user@lucene.apache.org Content-Type: multipart/alternative; boundary=001a11c14bf61db8db054e97cfed archived-at: Wed, 03 May 2017 05:20:12 -0000 --001a11c14bf61db8db054e97cfed Content-Type: text/plain; charset=UTF-8 Hi Joel, Thanks for the info. Regards, Edwin On 3 May 2017 at 02:04, Joel Bernstein wrote: > Also take a look at the documentation for the "fetch" streaming expression. > > Joel Bernstein > http://joelsolr.blogspot.com/ > > On Tue, May 2, 2017 at 2:03 PM, Joel Bernstein wrote: > > > Yes you join more then one collection with Streaming Expressions. Here > are > > a few things to keep in mind. > > > > * You'll likely want to use the parallel function around the largest > join. > > You'll need to use the join keys as the partitionKeys. > > * innerJoin: requires that the streams be sorted on the join keys. > > * innerHashJoin: has no sorting requirement. > > > > So a strategy for a three collection join might look like this: > > > > innerHashJoin(parallel(innerJoin(bigStream, bigStream)), smallerStream) > > > > The largest join can be done in parallel using an innerJoin. You can then > > wrap the stream coming out of the parallel function in an innerHashJoin > to > > join it to another stream. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Joel Bernstein > > http://joelsolr.blogspot.com/ > > > > On Mon, May 1, 2017 at 9:42 PM, Zheng Lin Edwin Yeo < > edwinyeozl@gmail.com> > > wrote: > > > >> Hi, > >> > >> Is it possible to join more than 2 collections using one of the > streaming > >> expressions (Eg: innerJoin)? If not, is there other ways we can do it? > >> > >> Currently, I may need to join 3 or 4 collections together, and to output > >> selected fields from all these collections together. > >> > >> I'm using Solr 6.4.2. > >> > >> Regards, > >> Edwin > >> > > > > > --001a11c14bf61db8db054e97cfed--