X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 133C9D70E7 for ; Mon, 22 Aug 2005 14:47:11 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 09881-05 for ; Mon, 22 Aug 2005 17:47:08 +0000 (GMT) Received: from hub.org (hub.org [200.46.204.220]) by svr1.postgresql.org (Postfix) with ESMTP id 7C97CD70CE for ; Mon, 22 Aug 2005 14:47:08 -0300 (ADT) Received: from localhost (av.hub.org [200.46.204.144]) by hub.org (Postfix) with ESMTP id C123364B82E for ; Mon, 22 Aug 2005 14:47:09 -0300 (ADT) Received: from hub.org ([200.46.204.220]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 21719-03 for ; Mon, 22 Aug 2005 17:47:05 +0000 (GMT) Received: from ganymede.hub.org (blk-222-82-85.eastlink.ca [24.222.82.85]) by hub.org (Postfix) with ESMTP id 3FA0064B84F for ; Mon, 22 Aug 2005 14:16:30 -0300 (ADT) Received: by ganymede.hub.org (Postfix, from userid 1000) id 674DD38232; Mon, 22 Aug 2005 14:16:30 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by ganymede.hub.org (Postfix) with ESMTP id 666D537FE2 for ; Mon, 22 Aug 2005 14:16:30 -0300 (ADT) Date: Mon, 22 Aug 2005 14:16:30 -0300 (ADT) From: "Marc G. Fournier" X-X-Sender: scrappy@ganymede.hub.org To: pgsql-sql@postgresql.org Subject: PL/SQL Function: self-contained transaction? Message-ID: <20050822141357.B1002@ganymede.hub.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by amavisd-new at hub.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.251 required=5 tests=[AWL=0.201, FORGED_RCVD_HELO=0.05] X-Spam-Level: X-Archive-Number: 200508/187 X-Sequence-Number: 22415 In PostgreSQL, as everyone knows, a QUERY == a transaction, unless wrap'd in a BEGIN/END explicitly ... how does that work with a function? is there an implicit BEGIN/END around the whole transaction, or each QUERY within the function itself? If the whole function (and all QUERYs inside of it) are considered one transaction, can you do a begin/end within the function itself to 'force' commit on a specific part of the function? ---- Marc G. Fournier Hub.Org Networking Services (http://www.hub.org) Email: scrappy@hub.org Yahoo!: yscrappy ICQ: 7615664