Date/time precision in 7.2

From: Steve Lane <slane(at)fmpro(dot)com>
To: PostgreSQL General Mailing List <pgsql-general(at)postgresql(dot)org>
Subject: Date/time precision in 7.2
Date: 2002-07-10 03:49:13
Message-ID: B95118E9.10014%slane@fmpro.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello all:

I just upgraded a large application from 7.1 to 7.2. Postgres back end (I
always say "postgres", not "postgresql" FWIW), PHP 4.1 front end. Certain
date related functions immediately began to break.

A little digging showed that the new date/time formats in 7.2 cause PHP's
strtotime() function to break. In the release notes for 7.2 I found this
item:

> Add precision to TIME, TIMESTAMP, and INVERVAL data types (Thomas)

Which I assume is what's causing PHP the problem -- it doesn't appear to
like the floating-point representation.

Question 1: is there a flavor of PGDATESTYLE that makes this representation
go away? I'm fine with only having accuracy down to the second. I tried the
listed values for PGDATESTYLE and could not suppress the format that's
breaking PHP.

Question 2: What exactly does this extra information in the timestamp
represent? Is it standard, or a postgres extension?

Thanks in advance for any help.

-- sgl

=======================================================
Steve Lane

Vice President
Chris Moyer Consulting, Inc.
833 West Chicago Ave Suite 203

Voice: (312) 433-2421 Email: slane(at)fmpro(dot)com
Fax: (312) 850-3930 Web: http://www.fmpro.com
=======================================================

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Marc G. Fournier 2002-07-10 04:20:58 Re: I am being interviewed by OReilly
Previous Message snmadhusudan 2002-07-10 03:48:04 Reconnect help