Re: [HACKERS] REGEXP_MATCHES() strange behavior with '^' and '$' pattern

2013-08-01 Thread Jeevan Chalke
On Thu, Aug 1, 2013 at 12:25 PM, Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > > > On Wed, Jul 31, 2013 at 7:47 PM, Tom Lane wrote: > >> Jeevan Chalke writes: >> > Oops forgot patch. >> > Attached now. >> >> Hmm ... I think the logic change is good, but two demerits for not fixing >

Re: [HACKERS] REGEXP_MATCHES() strange behavior with '^' and '$' pattern

2013-07-31 Thread Jeevan Chalke
On Wed, Jul 31, 2013 at 7:47 PM, Tom Lane wrote: > Jeevan Chalke writes: > > Oops forgot patch. > > Attached now. > > Hmm ... I think the logic change is good, but two demerits for not fixing > the adjacent comment. > I had a look over comments and somehow I found that OK. Anyway, updated comm

Re: [HACKERS] REGEXP_MATCHES() strange behavior with '^' and '$' pattern

2013-07-31 Thread Tom Lane
Jeevan Chalke writes: > Oops forgot patch. > Attached now. Hmm ... I think the logic change is good, but two demerits for not fixing the adjacent comment. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your su

Re: [HACKERS] REGEXP_MATCHES() strange behavior with '^' and '$' pattern

2013-07-31 Thread Jeevan Chalke
Oops forgot patch. Attached now. On Wed, Jul 31, 2013 at 6:03 PM, Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > Hi, > > While playing with regular expression I found some strange behavior of > regexp_matches() function. > > Consider following sql query and its output: > > postgres=#

[HACKERS] REGEXP_MATCHES() strange behavior with '^' and '$' pattern

2013-07-31 Thread Jeevan Chalke
Hi, While playing with regular expression I found some strange behavior of regexp_matches() function. Consider following sql query and its output: postgres=# select regexp_matches('1' || chr(10) || '2' || chr(10) || '3' || chr(10) || '4', '^', 'mg'); regexp_matches {""} {""}