Roman Scherer <ro...@burningswell.com> writes:
> Can someone explain to me what's the difference between quoting
> the `upper` and the `coalesce` function?

COALESCE is a keyword.

> What I found so far is, that the `upper` function can be found in
> the `pg_proc` table but not `coalesce`.

Yup.

> Does this mean that `coalesce` isn't a classical function and I
> shouldn't quote it? Is it instead a keyword, as described in
> the "Lexical Structure" section of the docs [2]? How can I find
> out which other functions are not meant to be quoted?

Yes, yes, and you already found one good way: if it doesn't have
a pg_proc entry then it's a special case of some sort or other.

Have you considered only quoting the function name if it actually
needs it, ie, contains special characters?

                        regards, tom lane


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to