X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 3B2AA533BB for ; Wed, 23 Mar 2005 17:02:50 +0000 (GMT) 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 50293-03 for ; Wed, 23 Mar 2005 17:02:45 +0000 (GMT) Received: from stark.xeocode.com (stark.xeocode.com [216.58.44.227]) by svr1.postgresql.org (Postfix) with ESMTP id 30FFF5338F for ; Wed, 23 Mar 2005 17:02:44 +0000 (GMT) Received: from localhost ([127.0.0.1] helo=stark.xeocode.com) by stark.xeocode.com with smtp (Exim 3.36 #1 (Debian)) id 1DE9Fb-0004aB-00; Wed, 23 Mar 2005 12:02:35 -0500 To: pgsql-general@postgresql.org Subject: Re: Delay INSERT References: <20050321131047.93504.qmail@web53406.mail.yahoo.com> <20050321161555.GA22145@winnie.fuhr.org> <14435275218.20050323193122@on.kg> <42418247.7070108@archonet.com> <758d5e7f05032308342828a03f@mail.gmail.com> In-Reply-To: <758d5e7f05032308342828a03f@mail.gmail.com> From: Greg Stark Organization: The Emacs Conspiracy; member since 1992 Date: 23 Mar 2005 12:02:35 -0500 Message-ID: <871xa670t0.fsf@stark.xeocode.com> Lines: 13 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.012 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200503/1140 X-Sequence-Number: 75455 Dawid Kuroczko writes: > PostgreSQL doesn't have such issues with blocking, so only difference > between INSERT and INSERT DELAYED from PostgreSQL's standpoint > would be waiting and not for the result... An insert can be blocked if there's a UNIQUE constraint and another transaction has an insert or update pending for the same key. If the other transaction commits you get a unique constraint violation, if it aborts your insert succeeds. -- greg