Skip site navigation (1) Skip section navigation (2)

Substring undocumented form

From: Thom Brown <thom(at)linux(dot)com>
To: pgsql-docs <pgsql-docs(at)postgresql(dot)org>
Subject: Substring undocumented form
Date: 2010-09-25 08:36:36
Message-ID: AANLkTik_6-gdHaekS7YN8BKN0Rwv8WpxdbaA5ha0Ld0F@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-docs
Hi all,

Someone submitted a comment to the documentation which made mention of
the fact that while we provide one form of the 3-parameter substring
function, we don't mention an alternative one.

substring(string from pattern for escape)
can be written:
substring(string, pattern, escape)

Curiously, this doesn't appear to be the same with similar functions.
For instance, the following can't be changed in a similar way:

overlay('Txxxxas' placing 'hom' from 2 for 4)
can't be written:
overlay('Txxxxas', 'hom', 2, 4)

position('om' in 'Thomas')
can't be written:
position('om', 'Thomas')

So this doesn't look like a general alternative form.  Is the
alternative form of substring deprecated or just missing from the
documentation?

Thanks

Thom Brown
Twitter: @darkixion
IRC (freenode): dark_ixion
Registered Linux user: #516935

Responses

pgsql-docs by date

Next:From: Robert HaasDate: 2010-09-25 13:40:08
Subject: Re: Substring undocumented form
Previous:From: Robert HaasDate: 2010-09-23 21:48:07
Subject: Re: Rename install-win32?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group