Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-24003

eZ Find: Solr facet field "attr_profiles_t" truncates object relations values

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Medium Medium
    • Resolution: Invalid
    • Affects Version/s: 5.4.1
    • Fix Version/s: Customer request
    • Labels:
      None
    • Environment:

      eZ Publish 5.4.1, eZ Find 5.4.1, Solr admin interface

      Description

      Steps to reproduce:

      1. Create new content class:

      Name: Profile
      Identifier: profile

      Add one attribute:

      Attribute Type: Text line

      • Name: Title
      • Identifier: title
      • Is required: checked
      • Searchable: checked

      2. Create a new content in content tree for the new class. Called it "Jeune Journaliste":

      Home
      	Tests
      		Jeune Journaliste
      

      3. Duplicate "Article" class, and add a new attribute of type "Object relations" to the new class. The new class is called "Article 2", and the new attribute is called "Profiles":

      Name: Article 2
      Identifier: article_2

      Attribute Type: Object relations

      • Name: Profiles
      • Identifier: profiles
      • Selection method: List with checkboxes
      • Allowed classes: profile
      • Is required: not checked
      • Searchable: checked
      • Default location: Tests

      4. Create a content for the new "article_2" class. Called it "13140 Test 1", and associated "Jeune Journaliste" content defined in step 2 to the "profile" object relations attribute:

      Home
      	Tests
      		13140 Test 1
      

      5. On Solr admin interface, execute this query:

      /select?q=*:*&fq=meta_class_identifier_ms:article_2&wt=json&indent=true&facet=true&facet.field=attr_profiles_t
      

      Result:

      {
        "responseHeader": {
          "status": 0,
          "QTime": 8,
          "params": {
            "q": "*:*",
            "facet.field": "attr_profiles_t",
            "indent": "true",
            "fq": "meta_class_identifier_ms:article_2",
            "wt": "json",
            "facet": "true",
            "_": "1423594692695"
          }
        },
        "response": {
          "numFound": 1,
          "start": 0,
          "docs": [
            {}
          ]
        },
        "facet_counts": {
          "facet_queries": {},
          "facet_fields": {
            "attr_profiles_t": [
              "jeun",
              1,
              "journalist",
              1
            ]
          },
          "facet_dates": {},
          "facet_ranges": {},
          "facet_intervals": {}
        }
      }
      

      This is not correct, since the values of "attr_profiles_t" are truncated - "jeun" should be "jeune", and "journalist" should be "journaliste".

        Activity

        Hide
        Petar Spanja (Inactive) added a comment -

        This is not really a bug, but a Solr feature (has nothing to do with eZ Find as such). Here faceting is performed on a analyzed field, so individual values there are tokenized strings. In version 2.2 eZ Find introduced dedicated field types for attributes in faceting context, see:

        https://doc.ez.no/Extensions/eZ-Publish-extensions/eZ-Find/eZ-Find-2.2/What-s-new-in-eZ-Find-2.2
        https://doc.ez.no/Extensions/eZ-Publish-extensions/eZ-Find/eZ-Find-LS-5.2.0/Basic-Configuration/Configuration-settings-eZ-Find#solr

        And also:

        http://share.ez.no/forums/extensions/ez-find/facets-truncated-values-on-ezstring

        I'm closing this as invalid.

        Show
        Petar Spanja (Inactive) added a comment - This is not really a bug, but a Solr feature (has nothing to do with eZ Find as such). Here faceting is performed on a analyzed field, so individual values there are tokenized strings. In version 2.2 eZ Find introduced dedicated field types for attributes in faceting context, see: https://doc.ez.no/Extensions/eZ-Publish-extensions/eZ-Find/eZ-Find-2.2/What-s-new-in-eZ-Find-2.2 https://doc.ez.no/Extensions/eZ-Publish-extensions/eZ-Find/eZ-Find-LS-5.2.0/Basic-Configuration/Configuration-settings-eZ-Find#solr And also: http://share.ez.no/forums/extensions/ez-find/facets-truncated-values-on-ezstring I'm closing this as invalid.
        Hide
        Jean-Luc Chassaing added a comment -

        I 'd like to add something here.
        The idea is to attach contents to an other content with the object relatations field and then use this field in facets. The problem is that in the facet results the words are cut. To refer to the example above if the name is "journaliste" the word will be cut in the facet result to become "journalist" and if the name has a space it goes worse "jeune journaliste" becomes "jeun".

        Show
        Jean-Luc Chassaing added a comment - I 'd like to add something here. The idea is to attach contents to an other content with the object relatations field and then use this field in facets. The problem is that in the facet results the words are cut. To refer to the example above if the name is "journaliste" the word will be cut in the facet result to become "journalist" and if the name has a space it goes worse "jeune journaliste" becomes "jeun".

          People

          • Assignee:
            Unassigned
            Reporter:
            Nuno Oliveira (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - Not Specified
              Not Specified
              Remaining:
              Remaining Estimate - 0 minutes
              0m
              Logged:
              Time Spent - 2 hours, 15 minutes
              2h 15m