Re: Re: Suggestion: Issue warning when calling SET TRANSACTION outside transaction block - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: Re: Suggestion: Issue warning when calling SET TRANSACTION outside transaction block
Date
Msg-id 20131126170237.GB6321@momjian.us
Whole thread Raw
In response to Re: Suggestion: Issue warning when calling SET TRANSACTION outside transaction block  (David Johnston <polobo@yahoo.com>)
List pgsql-hackers
On Tue, Nov 26, 2013 at 08:54:13AM -0800, David Johnston wrote:
> How about:
> 
> "Issuing <command> outside of a transaction has no effect and will provoke a
> warning."
> 
> I dislike "does no harm" because it can if someone thinks the current state
> is different than reality.
> 
> It is good to indicate that a warning is emitted if this is done in error;
> thus reinforcing the fact people should be looking at their warnings.
> 
> "when not inside" uses a negative modifier while "outside" is more direct
> and thus easier to read, IMO.  The phrase "transaction block" seems wordy so
> I omitted the word "block".

Every statement runs in a transaction so we can't omit "block".

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + Everyone has their own god. +



pgsql-hackers by date:

Previous
From: Stephen Frost
Date:
Subject: Re: Extension Templates S03E11
Next
From: Kevin Grittner
Date:
Subject: Re: PL/Python: domain over array support