pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: codeWarrior <gpatnude@hotmail.com>
To: pgsql-admin@postgresql.org
Subject: Re: Timestamp not working
Date: Tue, 15 Nov 2005 08:01:03 -0800
Message-ID: <dld0j2$h5u$1@news.hub.org> (raw)
References: <88odf.2261$fN5.887@newsfe6-gui.ntli.net>

CREATE TABLE mytable (

    id serial not null primary key,

    myvalue varchar(50),

    create_dt timestamp not null default now()

);

INSERT INTO mytable (myvalue) VALUES ('When was this record inserted ?');
SELECT * FROM mytable;


"Si" <si@hotmail.com> wrote in message
news:88odf.2261$fN5.887@newsfe6-gui.ntli.net...
>I have added a field to one of my PostgreSQL tables in the "Timestamp"
>datatype, but when I add a row to that table I don't get the date and time
>inserted into that column? Do I need to put a default value into the column
>too?
>







Message-ID: <dld0j2$h5u$1@news.hub.org>
Permalink:  ../dld0j2$h5u$1@news.hub.org/
Also on:    postgresql.org/message-id/dld0j2$h5u$1@news.hub.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-admin@postgresql.org
  Cc: gpatnude@hotmail.com
  Subject: Re: Timestamp not working
  In-Reply-To: <dld0j2$h5u$1@news.hub.org>
  References: <88odf.2261$fN5.887@newsfe6-gui.ntli.net> <dld0j2$h5u$1@news.hub.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