Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-4033

Using HstQuery#addOrderByDescending twice in combination with faceted nav: jcr:score seems ignored

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 5.3.0
    • None
    • None
    • 0.5
    • Flagged
    • Turing Sprint 162, Turing Sprint 163, Turing Sprint 164, Turing Sprint 178

    Description

      When using an HST free text query in combination with faceted navigation, and calling HstQuery#addOrderByDescending more than once, the ordering by "jcr:score" seems to be ignored.

      Reproduction

      • checkout release/2.2 of the test suite
      • at line 58 of AbstractFacetedComponnent, insert
        hstQuery.addOrderByDescending("jcr:score");
        hstQuery.addOrderByDescending("demosite:price");
      • build and run
      • in content, replace /content/documents/demosite/products with attached products.xml
      • visit the repository servlet to see jcr:scores:
        http://localhost:8080/cms/repository/?search-type=xpath&uuid=996bcac5-86cf-49b5-a7a3-16a74863e814&text=&text-limit=1000&xpath=content%2Fdocuments%2Fdemosite%2Fproducts%2F%2F*%5B%28%40hippo%3Aavailability%3D%27live%27%29+and+%28jcr%3Acontains%28.%2C+%27key%27%29%29%5D+order+by+%40demosite%3Aprice+descending%2C+%40jcr%3Ascore+descending&xpath-limit=1000&sql=&sql-limit=1000
      • hit http://localhost:8080/site/faceted/tag+cloud+browsing?query=key

      Expected: ordering by jcr:score should be applied first
      Actual: ordering by demosite:price is applied

      Observations:

      • seems to be limited to jcr:score. Doing this with demosite:color is okay
      • no problem when using one HstQuery#addOrderByDescending call

      See also screen shot.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jhoffman Jeroen Hoffman
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: