Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-2539

SQL2 query not working with filter (s.[stringa] = 'a' OR CONTAINS(s.[stringb], 'b'))

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.3.11, 1.4
    • core, query
    • None

    Description

      Create node /content/usergenerated/qtest with jcr:primaryType nt:unstrucuted.

      Add 2 String properties: stringa = "a", stringb = "b".

      Use query tool in CRX/DE to do SQL2 search:
      This search will find qtest:
      SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE([/content/usergenerated/]) AND (s.[stringa] = 'a' OR CONTAINS(s.[stringb], 'b'))
      This search will find qtest:
      SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE([/content/usergenerated/]) AND (CONTAINS(s.[stringb], 'b'))
      This search will not find qtest:
      SELECT * FROM [nt:base] AS s WHERE ISDESCENDANTNODE([/content/usergenerated/]) AND (s.[stringa] = 'x' OR CONTAINS(s.[stringb], 'b'))

      Attachments

        Issue Links

          Activity

            People

              thomasm Thomas Mueller
              cawong Calvin Wong
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: