Received: from sss.pgh.pa.us (sss.pgh.pa.us [216.151.103.158]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f4E1VkA85031 for ; Sun, 13 May 2001 21:31:46 -0400 (EDT) (envelope-from tgl@sss.pgh.pa.us) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.3/8.11.3) with ESMTP id f4E1VeR04665; Sun, 13 May 2001 21:31:40 -0400 (EDT) To: "Eric G. Miller" cc: PostgreSQL General Subject: Re: Bug with timestamp !!! In-reply-to: <20010513173629.B307@calico.local> References: <9dj2rq$1ij$1@news.tht.net> <20010512225651.A17727@calico.local> <3449.989767665@sss.pgh.pa.us> <20010513164929.A307@calico.local> <20010513173629.B307@calico.local> Comments: In-reply-to "Eric G. Miller" message dated "Sun, 13 May 2001 17:36:29 -0700" Date: Sun, 13 May 2001 21:31:40 -0400 Message-ID: <4662.989803900@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200105/591 X-Sequence-Number: 9450 "Eric G. Miller" writes: > After doing that, the results become consistent regardless of the order > of the calls. You can't use "memset(theTime, 0, sizeof(struct tm))" > because when tm_isdst = 0 it say daylight savings time is false (which > you don't know yet from a string like '2001-04-01 02:30:30'). But we don't do that --- we set tm_isdst = -1 so as to ask mktime's opinion whether the time is DST or not. That is the case that seems to have some history-dependent behavior ... regards, tom lane