Re: BUG #14623: pg_trgm doesn't correctly process some regexp with negative lookahead

From: Corey Csuhta <its+postgres(at)csuhta(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14623: pg_trgm doesn't correctly process some regexp with negative lookahead
Date: 2017-04-13 20:04:08
Message-ID: E2B01A4B-4530-406B-8D17-2F67CF9A16BA@csuhta.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

I don’t know if this is related or a separate bug, but I am also having this problem with the `+` operator and character classes. Very similar test case:

CREATE TABLE foobar (x text);
INSERT INTO foobar VALUES ('Trying +1/+1'),('Also doing +20/+20');
CREATE EXTENSION pg_trgm;
CREATE INDEX ON foobar USING gin (x gin_trgm_ops);
SET enable_seqscan TO on;
SELECT * FROM foobar WHERE x ~ '\+\d+\/\+\d+'; -- Returns both rows
SET enable_seqscan TO off;
SELECT * FROM foobar WHERE x ~ '\+\d+\/\+\d+'; -- Returns 0 rows

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Michael Paquier 2017-04-13 23:29:22 Re: BUG #14622: could not remove file "pg_xlog/RECOVERYXLOG": Permission denied
Previous Message Tom Lane 2017-04-13 19:24:21 Re: BUG #14623: pg_trgm doesn't correctly process some regexp with negative lookahead