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

Re: Fix for VACUUM in psql autocommit off

From: "Michael Paesold" <mpaesold(at)gmx(dot)at>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Fix for VACUUM in psql autocommit off
Date: 2004-09-19 20:34:25
Message-ID: 001001c49e88$0e345cb0$d604460a@zaphod (view raw or flat)
Thread:
Lists: pgsql-patches
Tom Lane wrote:


> If we're going to do that, we should also include the other statements
> that disallow execution in a transaction, and we should rename
> is_transact_command to something more appropriate (not to mention fix
> its comments).  A quick grep shows
>
> PreventTransactionChain((void *) stmt, "CREATE DATABASE");
> PreventTransactionChain((void *) dbname, "DROP DATABASE");
> PreventTransactionChain((void *) stmt, "CLUSTER");
> PreventTransactionChain((void *) dbname, "REINDEX DATABASE");
> PreventTransactionChain((void *) vacstmt, stmttype);
> PreventTransactionChain((void *) stmt, "CREATE TABLESPACE");
> PreventTransactionChain((void *) stmt, "DROP TABLESPACE");

> Handling the multi-keyword cases is going to take a nontrivial increment
> of functionality.  Perhaps while we're at it, we could teach this code
> about nested /* comments ...

Currently there is no need for nested comments, because those are only
single word queries. Or do I not understand what you mean by nested
comments? (There is code for ignore /* .. */ before the first keyword.)

Any suggestion how to that? I can think of a way myself, but it may not be
the best, as I don't consider C my natural language. I can try, or does
anyone else feel inclined to fix this?

Best Regards,
Michael Paesold


In response to

Responses

pgsql-patches by date

Next:From: Tom LaneDate: 2004-09-19 20:44:22
Subject: Re: Fix for VACUUM in psql autocommit off
Previous:From: Tom LaneDate: 2004-09-19 19:48:06
Subject: Re: Fix for VACUUM in psql autocommit off

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