Thread: BUG #6370: manual does not discuss transactional DDL

BUG #6370: manual does not discuss transactional DDL

From
ryan@cs.utah.edu
Date:
The following bug has been logged on the website:

Bug reference:      6370
Logged by:          Ryan Culpepper
Email address:      ryan@cs.utah.edu
PostgreSQL version: Unsupported/Unknown
Operating system:   not applicable
Description:=20=20=20=20=20=20=20=20

This is a documentation bug (or feature request), not a software bug.

There seems to be no discussion of transactional DDL in the manual itself
(that I could find). A brief Google search turned up the following relevant
pages:

 -
http://wiki.postgresql.org/wiki/Transactional_DDL_in_PostgreSQL:_A_Competit=
ive_Analysis
 - http://wiki.postgresql.org/wiki/Why_PostgreSQL_Instead_of_MySQL_2009 (see
section "Transactional DDL")
 - http://archives.postgresql.org/pgsql-advocacy/2007-08/msg00273.php (and
other messages in that thread)

But I could not find a place in the manual that authoritatively states that
DDL is transactional. (Such a page should probably also discuss things like
session variables, etc.)

Re: BUG #6370: manual does not discuss transactional DDL

From
Josh Kupershmidt
Date:
On Mon, Jan 2, 2012 at 2:52 AM,  <ryan@cs.utah.edu> wrote:

> This is a documentation bug (or feature request), not a software bug.

For future reference, the pgsql-docs list is probably the best place
for such concerns.

> There seems to be no discussion of transactional DDL in the manual itself
> (that I could find). A brief Google search turned up the following releva=
nt
> pages:
>
> =A0-
> http://wiki.postgresql.org/wiki/Transactional_DDL_in_PostgreSQL:_A_Compet=
itive_Analysis
> =A0- http://wiki.postgresql.org/wiki/Why_PostgreSQL_Instead_of_MySQL_2009=
 (see
> section "Transactional DDL")
> =A0- http://archives.postgresql.org/pgsql-advocacy/2007-08/msg00273.php (=
and
> other messages in that thread)
>
> But I could not find a place in the manual that authoritatively states th=
at
> DDL is transactional. (Such a page should probably also discuss things li=
ke
> session variables, etc.)

Note not every DDL command can be run from within a transaction block.
I think the basic documentation strategy has been to add a note on the
docs page for each such command, e.g.
  http://www.postgresql.org/docs/current/static/sql-vacuum.html
  http://www.postgresql.org/docs/current/static/sql-createdatabase.html

say "[command] cannot be run inside a transaction block".

I think a mention that transactional DDL is generally possible (and
useful) might be helpful, if there is a suitable spot in the manual.
There was also some agreement on the thread you linked to that
emphasizing this would be a good idea. Did you have a specific spot in
the manual in mind for such a note, or a preferred wording?

Josh