Received: from localhost (uranus.hub.org [200.46.204.60]) by postgresql.org (Postfix) with ESMTP id 2650E9FA1E2 for ; Mon, 13 Nov 2006 09:54:06 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.60]) (amavisd-new, port 10024) with ESMTP id 64702-07 for ; Mon, 13 Nov 2006 09:54:03 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from svr4.postgresql.org (svr4.postgresql.org [66.98.251.159]) by postgresql.org (Postfix) with ESMTP id 6E5309FA1DB for ; Mon, 13 Nov 2006 09:54:03 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.3 Received: from dougal.cranntara.net (unknown [217.112.91.201]) by svr4.postgresql.org (Postfix) with ESMTP id C42AE5AF8C4 for ; Mon, 13 Nov 2006 13:54:02 +0000 (GMT) Received: from client-264-p-1-lns.glfd.dial.virgin.net ([81.103.145.7] helo=bolek.coachhouse) by dougal.cranntara.net with asmtp (Exim 3.36 #1 (Debian)) id 1GjcHl-0000Wc-00 for ; Mon, 13 Nov 2006 13:55:41 +0000 Received: (Exim 3.36) #1 (Debian)) protocol: esmtp id 1Gjc8P-0000Sl-00 ; Mon, 13 Nov 2006 13:46:01 +0000 Message-ID: <45587718.2010009@numerixtechnology.de> Date: Mon, 13 Nov 2006 13:46:00 +0000 From: T E Schmitz Reply-To: mailreg@numerixtechnology.de User-Agent: Debian Thunderbird 1.0.7 (X11/20051017) X-Accept-Language: en-us, en MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: max (timestamp,timestamp) Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.136 tagged_above=0 required=5 tests=BAYES_50, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200611/126 X-Sequence-Number: 26778 I tried the following query but the query fails as "function max (timestamp w. timezone,timestamp w. timezone) does not exist" SELECT id, MAX(last_updated, (SELECT MAX (last_updated) FROM product_category_member WHERE product_category_member.id = product_category.id)) FROM product_category product_category.last_updated and product_category_member.last_updated are timestamps with timezone. Is there any other way I can produce this result -- Regards, Tarlika Elisabeth Schmitz