Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 5E76B633343 for ; Tue, 2 Feb 2010 01:54:23 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 80735-02 for ; Tue, 2 Feb 2010 05:54:12 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-yx0-f188.google.com (mail-yx0-f188.google.com [209.85.210.188]) by mail.postgresql.org (Postfix) with ESMTP id E2E5D632F56 for ; Tue, 2 Feb 2010 01:54:12 -0400 (AST) Received: by yxe26 with SMTP id 26so923069yxe.28 for ; Mon, 01 Feb 2010 21:54:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:references:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:x-mailer :mime-version:subject:date:cc; bh=x8+Fq5S/H3UaJ1Y39sIbX/mPoDxoAmC89Ykh7ZyGBBw=; b=TWgFQRnWcy1XgY9ohN68fM6VFJCZ8VLxsoYg6LQsMa/DqmIjT6HqK/ozJx52OB3noL nHlksliUvD7txNgMdtk0hTTsBrYH2sXp2t36MTz8zahxM2B5UHM3DMneIv0RaPenc6Fi sOJ0xn64ZBxuy3Me+Rn0MBRZ5nRZdEymAYM7g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=references:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:x-mailer:mime-version:subject:date:cc; b=gcphW2BOA7w+msmGwdYMuLoh6S5KNCK6IlCG3ujdpy4jeHy2h6I1ajNuBh7AcuAapa d4qtsS1KGnOfn89URn1WryqwZdcNGvnQc16wfIsVOFL0jSMrXqBuFe2BWXrtKkBvLPPG OyKyBzEeAG+T4FTu3jM4QKWePYga5HP9E0gJ0= Received: by 10.91.19.17 with SMTP id w17mr4902740agi.54.1265090052051; Mon, 01 Feb 2010 21:54:12 -0800 (PST) Received: from ?192.168.0.11? (cpe-76-94-116-90.socal.res.rr.com [76.94.116.90]) by mx.google.com with ESMTPS id 4sm2037703ywi.9.2010.02.01.21.54.10 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 01 Feb 2010 21:54:10 -0800 (PST) References: <20100202045701.93A404B1C73@mail175-236.sinamail.sina.com.cn> Message-Id: From: Richard Broersma To: "wyx6fox@sina.com" In-Reply-To: <20100202045701.93A404B1C73@mail175-236.sinamail.sina.com.cn> Content-Type: text/plain; charset=us-ascii; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit X-Mailer: iPod Mail (7D11) Mime-Version: 1.0 (iPod Mail 7D11) Subject: Re: the jokes for pg concurrency write performance Date: Mon, 1 Feb 2010 21:54:07 -0800 Cc: "pgsql-performance@postgresql.org" X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.001 tagged_above=-10 required=5 tests=BAYES_50=0.001 X-Spam-Level: X-Archive-Number: 201002/8 X-Sequence-Number: 37429 On Feb 1, 2010, at 8:57 PM, wyx6fox@sina.com wrote: > i found a joke ,maybe this joke concurrency strategy is the > designer's pround idea, but i think it is a joke , next let me > describe the problems: > I would suggest that the behavior that you dislike so much is really not idea of the postgresql developers as much as it is of Prof. Codd and the ANSI-SQL committee. I wonder if a creditable relational DBMS exists that doesn't behave in exactly the way you've described? > UPDATE webpages SET hits = hits + 1 WHERE url ='some url '; > > i say ,u should no kill concurrency performance > One alternative design would be to log the timestamp of your web page hits rather than update a hits count field. Once you have this design, if the table becomes volumous with historical logs you have the choice the use horizontal table partitioning or you can roll up all of the historical logs into an aggregating materialized view(table). Regarding all of the jokes you mentioned, I found them all to be very funny indeed. :) Regards, Richard