Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-16161

Filtering a livetable on the doc.content property with content larger than 255 characters does not work as expected

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 11.0.3
    • Fix Version/s: None
    • Component/s: LiveTable
    • Labels:
      None
    • Environment:
      PostgreSQL
    • Difficulty:
      Unknown
    • Similar issues:

      Description

      Steps to reproduce

      • Create a livetable with the "doc.content" column as filterable, with partial match:
        'doc.content': {"filterable":true, "match": "partial"}
      • Add some extra parameters for filtering out only pages whose content matches a given string, for example: 'extraParams':
        '&doc.content=loremipsum'
      • Make sure that at least one of the expected livetable entries has some content containing the entered string.
      • Display the corresponding livetable.

      Expected behaviour

      • The filtered livetable should contain at least one page: the one containing the string declared in the extra parameters.

      Actual behaviour

      • When the first extra parameter string occurrence has an index higher than 256 in the page content, no match is found.

      Comment

      • The behaviour occurs at least with PostgreSQL. It seems to be due to the fact the the str SQL function used in macro livetable_addColumnToQuery will return at most 256 characters.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              slauriere slauriere
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: