pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Thomas Good <tomg@sqlclinic.net>
To: Postgres SQL List <pgsql-sql@postgreSQL.org>
Subject: Date Anomaly??
Date: Tue, 6 May 2003 16:05:57 -0400 (EDT)
Message-ID: <Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org> (raw)

Hi!

When I run this from the psql monitor:

SELECT SUBSTR(CURRENT_DATE - INTERVAL '1 MONTH',0,11);
it returns - 2003-04-06 which is the desired behaviour.

Inside a CGI/DBI script it returns:

Sun Apr 06

Anyone have any idea what is going on here!?

Thanks!


-----------------------------------------------------------------------
Thomas Good                                  e-mail: tomg@sqlclinic.net
Programmer/Analyst                           phone:   (+1) 718.818.5528
Residential Services                         fax:     (+1) 718.818.5056
Behavioral Health Services, SVCMC-NY         mobile:  (+1) 917.282.7359

// Das ist die Kunst - wie man alles verhunzt.




view thread (10+ messages)  latest in thread

Message-ID: <Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org>
Permalink:  ../Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org/
Also on:    postgresql.org/message-id/Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: tomg@sqlclinic.net
  Subject: Re: Date Anomaly??
  In-Reply-To: <Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org>
  References: <Pine.LNX.4.44.0305061603070.9996-100000@q8.nrnet.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox