Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id C04F6475CB1 for ; Tue, 24 Sep 2002 12:01:39 -0400 (EDT) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id 346DC475AE5 for ; Tue, 24 Sep 2002 12:01:39 -0400 (EDT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.5/8.12.5) with ESMTP id g8OG0DhR001566; Tue, 24 Sep 2002 12:00:13 -0400 (EDT) To: "Josh Berkus" Cc: Manfred Koizar , Bruce Momjian , Aaron Held , Roberto Mello , Neil Conway , pgsql-sql@postgresql.org Subject: Re: [GENERAL] CURRENT_TIMESTAMP In-reply-to: References: Comments: In-reply-to "Josh Berkus" message dated "Tue, 24 Sep 2002 08:05:59 -0700" Date: Tue, 24 Sep 2002 12:00:13 -0400 Message-ID: <1565.1032883213@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200209/308 X-Sequence-Number: 9585 "Josh Berkus" writes: > So, if I've got this straight: > [ snip ] > ... thus changing only current_timestamp. Yeah, that's more or less what I was thinking. The argument for changing current_timestamp seems to be really just spec compliance; that doesn't apply to now() or timeofday(). > Better yet, how about we introduce a parameter to now()? Example: > now() or now('transaction') returns the transaction timestamp. > now('statement') returns the statement timestamp > now('immediate') returns the timestamp at the exact time the function > is called. I like this. > We could introduce the new version of now() in 7.4, encourage everyone > to use it instead of other timestamp calls, and then in 7.5 change the > behavior of current_timestamp for SQL92 compliance. I'd be inclined to just do it; we have not been very good about following through on multi-version sequences of changes. And the folks who want a standard-compliant current_timestamp aren't going to want to migrate to now('statement') instead ... regards, tom lane