Re: [GENERAL] regexp_matches where clause - PG 9.1 - Mailing list pgsql-general

From Patrick B
Subject Re: [GENERAL] regexp_matches where clause - PG 9.1
Date
Msg-id CAJNY3iuXHV8oH6U=RQSy1Q7Wn4st4x2=OYZ4uHk9X27Lbtkaog@mail.gmail.com
Whole thread Raw
In response to Re: [GENERAL] regexp_matches where clause - PG 9.1  ("David G. Johnston" <david.g.johnston@gmail.com>)
Responses Re: [GENERAL] regexp_matches where clause - PG 9.1  (Arjen Nienhuis <a.g.nienhuis@gmail.com>)
Re: [GENERAL] regexp_matches where clause - PG 9.1  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-general


2017-04-07 14:08 GMT+12:00 David G. Johnston <david.g.johnston@gmail.com>:
On Thu, Apr 6, 2017 at 6:33 PM, Patrick B <patrickbakerbr@gmail.com> wrote:
When actually I just want the 'main''

​SELECT * FROM tbl WHERE path_name ~ '/main$' ?

David J.


David,
That won't work.

When performing the select, I got:

/{s3bucket}/filesuser/client/27801123/attachment/4510/file/1113/small/main

when actually i want:

/{s3bucket}/filesuser/client/27801123/attachment/4510/main


Patrick.


pgsql-general by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: [GENERAL] regexp_matches where clause - PG 9.1
Next
From: Arjen Nienhuis
Date:
Subject: Re: [GENERAL] regexp_matches where clause - PG 9.1