clarify Regular Expression Match Operators

Started by PG Bug reporting formover 8 years ago2 messagesdocs
Jump to latest
#1PG Bug reporting form
noreply@postgresql.org

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/10/static/functions-matching.html
Description:

Table 9.14 Regular Expression Match Operators
It is not clear (to me)where I would put one of these operators. The Example
column does not make sense to me.

#2Bruce Momjian
bruce@momjian.us
In reply to: PG Bug reporting form (#1)
Re: clarify Regular Expression Match Operators

On Sat, Jan 13, 2018 at 02:59:06PM +0000, PG Doc comments form wrote:

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/10/static/functions-matching.html
Description:

Table 9.14 Regular Expression Match Operators
It is not clear (to me)where I would put one of these operators. The Example
column does not make sense to me.

Uh, you can use those regular expressions any place you would use an
operator:

SELECT 'thomas' ~ '.*thomas.*';
?column?
----------
t

or in a where clause, e.g. WHERE col ~ 'ab.*c'. Not sure how we can
improve the docs here.

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +