pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: atrigent@ccs.neu.edu
To: pgsql-bugs@postgresql.org
Subject: BUG #6612: Functions can be called inside CHECK statements
Date: Wed, 25 Apr 2012 10:33:10 +0000
Message-ID: <E1SMzX4-0004Is-FF@wrigleys.postgresql.org> (raw)

The following bug has been logged on the website:

Bug reference:      6612
Logged by:          Ari Entlich
Email address:      atrigent@ccs.neu.edu
PostgreSQL version: 9.1.2
Operating system:   Windows?
Description:        

Seeing as Postgres does not allow sub-queries in CHECK constraints yet, it
doesn't make any sense to me for it to allow function calls, since functions
can perform queries. Additionally, if a function is called from a check
constraint and that function executes a query, the change that caused the
check constraint to fire does not appear to be "visible" to the query.
Therefore, calling functions in check constraints does not have the ability
to check whether that change is valid, making it mostly useless.




view thread (9+ messages)  latest in thread

Message-ID: <E1SMzX4-0004Is-FF@wrigleys.postgresql.org>
Permalink:  ../E1SMzX4-0004Is-FF@wrigleys.postgresql.org/
Also on:    postgresql.org/message-id/E1SMzX4-0004Is-FF@wrigleys.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: atrigent@ccs.neu.edu
  Subject: Re: BUG #6612: Functions can be called inside CHECK statements
  In-Reply-To: <E1SMzX4-0004Is-FF@wrigleys.postgresql.org>
  References: <E1SMzX4-0004Is-FF@wrigleys.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox