Add new SQL function, format(text).

Robert Haas <rhaas@postgresql.org>

Commit: 750487077802861a2accd94164166747ec311fa4
Author: Robert Haas <rhaas@postgresql.org>
Date: 2010-11-21T03:33:27Z
Releases: 9.1.0
Add new SQL function, format(text).

Currently, three conversion format specifiers are supported: %s for a
string, %L for an SQL literal, and %I for an SQL identifier.  The latter
two are deliberately designed not to overlap with what sprintf() already
supports, in case we want to add more of sprintf()'s functionality here
later.

Patch by Pavel Stehule, heavily revised by me.  Reviewed by Jeff Janes
and, in earlier versions, by Itagaki Takahiro and Tom Lane.

Files