Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.0.5, 10.0.6
    • 10.0.7
    • None
    • None
    • Centos 6.4

    Description

      Since the switch to pcre, word boundary queries such as SELECT 'a word a' REGEXP '[[:<:]]word[[:>:]]'; no longer work because it tries to parse [[:<:]] as a character class name.

      Attachments

        Activity

          Hi James.

          This is a non-standard extension in the old regex library.
          We'll think what we can do to provide backward compatibility
          for this syntax.

          In the meanwhile please use this syntax with PCRE:

          SELECT 'a word a' REGEXP '\\bword
          b';

          bar Alexander Barkov added a comment - Hi James. This is a non-standard extension in the old regex library. We'll think what we can do to provide backward compatibility for this syntax. In the meanwhile please use this syntax with PCRE: SELECT 'a word a' REGEXP '\\bword b';
          jamessharpe James Sharpe added a comment -

          Does that syntax work in mysql too? The software I'm seeing the issue with is civicrm so I'll push this fix upstream if it works for mysql too.

          jamessharpe James Sharpe added a comment - Does that syntax work in mysql too? The software I'm seeing the issue with is civicrm so I'll push this fix upstream if it works for mysql too.
          bar Alexander Barkov added a comment - - edited

          Unfortunately, the '\\bword
          b' syntax does not work in MySQL. It's a PCRE syntax.

          Anyway, we have a good news for you:
          This incompatibility will most likely be fixed in the next PCRE release.
          Philip Hazel (the PCRE maintainer) kindly argeed to add support
          for this non-standard syntax ('[[:<:]]' and '[[:>:]]') into PCRE and
          gave us a patch. I'll apply the patch to the PCRE library bundled
          with Maria. So the next MariaDB release will also support this syntax again.

          bar Alexander Barkov added a comment - - edited Unfortunately, the '\\bword b' syntax does not work in MySQL. It's a PCRE syntax. Anyway, we have a good news for you: This incompatibility will most likely be fixed in the next PCRE release. Philip Hazel (the PCRE maintainer) kindly argeed to add support for this non-standard syntax ('[ [:<:] ]' and '[ [:>:] ]') into PCRE and gave us a patch. I'll apply the patch to the PCRE library bundled with Maria. So the next MariaDB release will also support this syntax again.

          Fixed in 10.0.

          bar Alexander Barkov added a comment - Fixed in 10.0.

          People

            bar Alexander Barkov
            jamessharpe James Sharpe
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.