Return-Path: X-Original-To: apmail-lucene-solr-user-archive@minotaur.apache.org Delivered-To: apmail-lucene-solr-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E409D18781 for ; Thu, 4 Jun 2015 07:22:58 +0000 (UTC) Received: (qmail 86358 invoked by uid 500); 4 Jun 2015 07:22:54 -0000 Delivered-To: apmail-lucene-solr-user-archive@lucene.apache.org Received: (qmail 86291 invoked by uid 500); 4 Jun 2015 07:22:54 -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 86280 invoked by uid 99); 4 Jun 2015 07:22:54 -0000 Received: from Unknown (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Jun 2015 07:22:54 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 776211A43EF for ; Thu, 4 Jun 2015 07:22:53 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.98 X-Spam-Level: X-Spam-Status: No, score=0.98 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01] autolearn=disabled Received: from mx1-eu-west.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id ktfIIkPKSnuF for ; Thu, 4 Jun 2015 07:22:52 +0000 (UTC) Received: from mail-wg0-f42.google.com (mail-wg0-f42.google.com [74.125.82.42]) by mx1-eu-west.apache.org (ASF Mail Server at mx1-eu-west.apache.org) with ESMTPS id 5188620C4B for ; Thu, 4 Jun 2015 07:22:52 +0000 (UTC) Received: by wgbgq6 with SMTP id gq6so26369744wgb.3 for ; Thu, 04 Jun 2015 00:22:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=TKeijLTvvT+KZ8+0K5YhkXGwcdD7EPGAzFwCcbIV60M=; b=YcY3rc71yuzsJFxf86X73NTnAK1v8EmJz1CbXRkgHtzSw4CEtZc37fmFV5z6M6AfMI 9bnSWpVP3dhcbDujiF4mPHszPtG/b0UwUswzZnhAJwCWhBzO2TeB8M0EldqOduze3DaR gZl6lULjbDQJ1yLl0crTjMSGiXHYavoA3nLfv1i3z2BebbBO0LjrFi/l7NSMRQrrMbpo 7pftiXBb1/7GB//kjNO6xJDKjNnV48SghKf5FW8imNNaMrrQcI3OKIPwP2xsdW2jd6W8 8qI2ob9jJ/Imux68SV5Qfk+QNdFqX/DakIFrqiEBhNyaaZ17y1PA6ytJM24h6wxBlfYN /gpg== X-Gm-Message-State: ALoCoQk42LMgGk07iuhMwvLVxfBwHFOsP7Ac2fyPAH1Lve2jRIqPKrGgU6+jljJDwSYukOWLeppH MIME-Version: 1.0 X-Received: by 10.180.97.129 with SMTP id ea1mr50231910wib.24.1433402572068; Thu, 04 Jun 2015 00:22:52 -0700 (PDT) Received: by 10.27.213.79 with HTTP; Thu, 4 Jun 2015 00:22:52 -0700 (PDT) X-Originating-IP: [78.110.143.226] Date: Thu, 4 Jun 2015 09:22:52 +0200 Message-ID: Subject: When using Dismax, Solr 5.1 tries to compare the entire field to the search string, instead of only using keywords From: Wouter Admiraal To: solr-user@lucene.apache.org Content-Type: text/plain; charset=UTF-8 Hi all. Sorry about the title, but I don't know how to be more explicit than that. I am updating a Solr 1.4 install to Solr 5.1. I went through all the changes, updated my schema.xml, etc. Everything works (I re-indexed instead of migrating the existing one). I can search for documents, no problem there. Where I do have a problem is with dismax. It doesn't behave like before. It must a configuration issue, or maybe I never really understood how it is supposed to work. I have 2 documents, which can be summarized as follows: { "label": "Food Inc", "keywords": ["Food", "Nutrition"] } { "label": "Food check online", "keywords": ["Internet", "Health"] } If I disable dismax and search for "Food" (?q=Food), I find both documents. So far, so good. If I turn dismax on and add a boost to the label, I get 0 results (?q=Food&defType=dismax&qf=label^3.0). If I turn dismax on and add a boost to the keywords, I get 1 result ("Food Inc", which has a keyword "Food"; ?q=Food&defType=dismax&qf=keywords^2.0). So, from what I understand, it tries to match the search term *exactly* when enabling dismax, but uses a "contains keyword" logic when disabling dismax (same for edismax). Which means "Food" !== "Food Inc" with dismax on. When I turn on debug, I get the following: "debug": { "rawquerystring": "Food", "querystring": "Food", "parsedquery": "(+DisjunctionMaxQuery((label:Food^3.0)) ())/no_coord", "parsedquery_toString": "+(label:Food^3.0) ()", "explain": {}, "QParser": "DisMaxQParser", "altquerystring": null, "boostfuncs": null, ... } I don't understand how/why this doesn't use a "contains" operator. This was the behavior on the old 1.4 instance. I went through the changelog for 1.4 to 5.1, but I don't find any explicit information about dismax behaving differently, except the "mm" parameter needs a default. I tried many values for mm (including 0, 100%, 100, etc) but to no avail. Thanks for your help. Best regards, Wouter Admiraal