Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-30582

Inappropriate results in faceted search when using both keyword and file type (extension)

    Details

      Description

      Steps to reproduce
      1. upload two jpg file, named with "pic 1" and "image 1"
      2. upload a png file, named with "pic 2"
      3. add search portlet to a page
      4. configure search portlet, and use "advanced" mode and insert the attached text into the textarea somwhere into the default code (but NOT DELETE the default code).
      5. search with the keyword "image" (you should see 1 result, "image 1")
      6. choose jpg as file type
      7. you should see only "image 1" in result list, but because of the bug, there are two items in the list
      "pic 1" (because of the extension) and "image 1" (because of the keyword search).
      8. search with the keyword "jpg" and without facet-extension
      9. you should see two results

      Description

      Let assume, that the keyword is "pic" and the extension is "jpg".
      Our query string will be this (only the appropriate part):
      +extension:jpg +( title:pic ... extension:jpg)

      Where the first part +extension:jpg is because of the file type selection, and the +( title:pic ... extension:jpg) part is because of the keyword search.

      Which is surely wrong, because the good search string would be this:
      +extension:jpg +( title:pic ... extension:pic)

      We should know if the search-field is faceted or not. If faceted, than we should use keyword.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  7 years, 30 weeks, 2 days ago

                  Packages

                  Version Package
                  6.1.30 EE GA3
                  6.2.0 CE M2