Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eOFmS-0007at-9z for pgsql-general@arkaria.postgresql.org; Mon, 11 Dec 2017 04:33:28 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eOFmR-0000Wl-KF for pgsql-general@arkaria.postgresql.org; Mon, 11 Dec 2017 04:33:27 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1eOFmR-0000Wb-D6 for pgsql-general@lists.postgresql.org; Mon, 11 Dec 2017 04:33:27 +0000 Received: from n3.nabble.com ([162.255.23.22]) by magus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1eOFmO-0001Hv-18 for pgsql-general@postgresql.org; Mon, 11 Dec 2017 04:33:26 +0000 Received: from n3.nabble.com (localhost [127.0.0.1]) by n3.nabble.com (Postfix) with ESMTP id 6BFFA9FF5469 for ; Sun, 10 Dec 2017 21:33:21 -0700 (MST) Date: Sun, 10 Dec 2017 21:33:21 -0700 (MST) From: Jim Finnerty To: pgsql-general@postgresql.org Message-ID: <1512966801439-0.post@n3.nabble.com> In-Reply-To: References: Subject: Re: Removing INNER JOINs MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk FK constraint enforcement may be deferred, but only to the end of the DML transaction. Can someone provide an example where a SELECT statement that is not in that DML transaction and that can view only committed data can see a FK-side row that doesn't join with any PK-side row? I don't think I understand why the volatile function scenario. Can a volatile function somehow circumvent FK enforcement? If not, then why is the volatile function scenario different than any other DML with respect to the enforcement of FK constraints? thank you, /Jim F -- Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html