X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 647C8D1B1BE for ; Fri, 23 Jul 2004 18:43:46 -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 47652-09 for ; Fri, 23 Jul 2004 21:43:44 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 419ACD1B1A1 for ; Fri, 23 Jul 2004 18:43:42 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i6NLhhcK028392; Fri, 23 Jul 2004 17:43:44 -0400 (EDT) To: Yi LIN Cc: pgsql-jdbc@postgresql.org Subject: Re: conflict txns in serialization isolation In-reply-to: References: Comments: In-reply-to Yi LIN message dated "Fri, 23 Jul 2004 17:19:59 -0400" Date: Fri, 23 Jul 2004 17:43:43 -0400 Message-ID: <28391.1090619023@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=1.1 tagged_above=0.0 required=5.0 tests=MAILTO_TO_SPAM_ADDR X-Spam-Level: * X-Archive-Number: 200407/274 X-Sequence-Number: 10658 Yi LIN writes: > Read-committed is different from Snapshot in that > Read-Committed txn will read data committed before read operation starts > but snapshot txn will read data committed before the whole txn starts. That's a true statement for SELECT, but a read-committed UPDATE will in fact find and update the latest version of the row; it won't cause changes to be lost, even if they occurred after the UPDATE statement as a whole started. The same is true of SELECT FOR UPDATE. I'm not sure how that relates to your previous observations though. Can you duplicate the apparent misbehavior in psql? I can't. regards, tom lane