Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 3D4F51337B69 for ; Sun, 1 May 2011 15:48:59 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 50300-08 for ; Sun, 1 May 2011 18:48:58 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by mail.postgresql.org (Postfix) with ESMTP id 608B51337990 for ; Sun, 1 May 2011 15:48:57 -0300 (ADT) Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by wwwmaster.postgresql.org (8.14.3/8.14.3) with ESMTP id p41ImvKZ084138 for ; Sun, 1 May 2011 18:48:57 GMT (envelope-from www@wwwmaster.postgresql.org) Received: (from www@localhost) by wwwmaster.postgresql.org (8.14.3/8.14.3/Submit) id p41ImvOT084137; Sun, 1 May 2011 18:48:57 GMT (envelope-from www) Date: Sun, 1 May 2011 18:48:57 GMT Message-Id: <201105011848.p41ImvOT084137@wwwmaster.postgresql.org> To: pgsql-bugs@postgresql.org Subject: BUG #6001: date_trunc is not timezone aware From: "Marek Nos" Content-Type: text/plain; charset=utf-8 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 201105/1 X-Sequence-Number: 30140 The following bug has been logged online: Bug reference: 6001 Logged by: Marek Nos Email address: marek.nos@centrum.cz PostgreSQL version: 9.0 Operating system: Windows 7 Description: date_trunc is not timezone aware Details: and other like extract() as well SELECT date_trunc('day', '2011-05-02 02:00:00+05'::timestamptz) I would expect result as '2011-05-02 00:00:00+05' but '2011-05-01 00:00:00+02' is given (pre conversion to server timezone is done first)