Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ez1J8-0003ik-5g for pgsql-bugs@arkaria.postgresql.org; Thu, 22 Mar 2018 14:35:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1ez1J7-0002ST-38 for pgsql-bugs@arkaria.postgresql.org; Thu, 22 Mar 2018 14:35:09 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ez1J6-0002SJ-TR for pgsql-bugs@lists.postgresql.org; Thu, 22 Mar 2018 14:35:08 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1ez1J3-0000sK-HT for pgsql-bugs@lists.postgresql.org; Thu, 22 Mar 2018 14:35:08 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w2MEZ2uZ032427; Thu, 22 Mar 2018 10:35:02 -0400 From: Tom Lane To: rgc@rgc1.inka.de cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #15127: epoch lies 1 hour ahead In-reply-to: <152172494965.9509.10320952862957414465@wrigleys.postgresql.org> References: <152172494965.9509.10320952862957414465@wrigleys.postgresql.org> Comments: In-reply-to =?utf-8?q?PG_Bug_reporting_form?= message dated "Thu, 22 Mar 2018 13:22:29 -0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <32425.1521729302.1@sss.pgh.pa.us> Date: Thu, 22 Mar 2018 10:35:02 -0400 Message-ID: <32426.1521729302@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk =?utf-8?q?PG_Bug_reporting_form?= writes: > I think there is a bug in 10.2. > Compared to my old 9.1.18 installation, extracted epoch values lie 1h > ahead. Hm. I get regression=# select extract(epoch from timestamptz '2018-03-22 11:50:00+01'); date_part ------------ 1521715800 (1 row) in either HEAD or 9.1.24 (don't have a build of 9.1.18 laying about), and this agrees with outside tools such as "date", so I think it's the right answer. I'm not sure why your 9.1.18 installation is giving a different answer. At this time of year, though, a discrepancy in opinions about the DST transition date is the first theory that springs to mind. I wonder which version of the tzdata database your 9.1.18 is using. I also find this in the 9.1.23 release notes: Update our copy of the timezone code to match IANA's tzcode release 2016c (Tom Lane) This is needed to cope with anticipated future changes in the time zone data files. It also fixes some corner-case bugs in coping with unusual time zones. so it's not out of the question that the behavior discrepancy arises from a since-fixed bug. regards, tom lane