RE: regex failing

2023-06-27 Thread Zahir Lalani
> -Original Message- > > > > Hi All > > > > > > > > Got a weird one. I am using the regex below to case match numeric only > values. > > > > > > > > '^([0-9]+[.]?[0-9]*)$' > > > > > > > > This works well by and large but not for a value like “1234:567”. This seems > to match positive and th

Re: regex failing

2023-06-27 Thread Sergey Fukanchik
On Tue, 27 Jun 2023 at 14:59, Zahir Lalani wrote: > > Hi All > > > > Got a weird one. I am using the regex below to case match numeric only values. > > > > '^([0-9]+[.]?[0-9]*)$' > > > > This works well by and large but not for a value like “1234:567”. This seems > to match positive and then fail

Re: regex failing

2023-06-27 Thread Steve Baldwin
Probably not much help but it seems to work ok for me (unless I'm doing something stupid). You didn't actually say how/where you were doing the regex match, but the '~' operator seems to work ok. [~/git/caas-sqs-consumer] psql psql (15.3 (Homebrew), server 13.7) SSL connection (protocol: TLSv1.2,

Re: regex failing

2023-06-27 Thread David G. Johnston
On Tue, Jun 27, 2023 at 11:59 AM Zahir Lalani wrote: > Hi All > > > > Got a weird one. I am using the regex below to case match numeric only > values. > > > > '^([0-9]+[.]?[0-9]*)$' > > > > This works well by and large but not for a value like “1234:567”. This > seems to match positive and then f

regex failing

2023-06-27 Thread Zahir Lalani
Hi All Got a weird one. I am using the regex below to case match numeric only values. '^([0-9]+[.]?[0-9]*)$' This works well by and large but not for a value like “1234:567”. This seems to match positive and then fails due to not being an actual number in the subsequent cast. Any ideas? (PG13