pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Larry Rosenman <ler@lerctr.org>
To: Brian Ward <brian0@verizon.net>
Cc: pgsql-sql@postgresql.org
Subject: Re: timestamp
Date: 07 Oct 2002 07:25:08 -0500
Message-ID: <1033993509.311.17.camel@lerlaptop> (raw)
In-Reply-To: <anphrb$24se$1@news.hub.org>
References: <anphrb$24se$1@news.hub.org>

On Sun, 2002-10-06 at 09:41, Brian Ward wrote:
> How do I create a time stamp column in a table that default to the current
> time
> when a row is inserted?
> I tried putting in now() as the default but I have something wrong
> with the syntax or something I think
> Any one have an example of a table creation script that has a timestamp
> column?
"comment_timestamp" timestamp(0) with time zone DEFAULT now()

that's a live one from a table I have.


-- 
Larry Rosenman                     http://www.lerctr.org/~ler
Phone: +1 972-414-9812                 E-Mail: ler@lerctr.org
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749




view thread (13+ messages)  latest in thread

Message-ID: <1033993509.311.17.camel@lerlaptop>
Permalink:  ../1033993509.311.17.camel@lerlaptop/
Also on:    postgresql.org/message-id/1033993509.311.17.camel@lerlaptop

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: ler@lerctr.org, brian0@verizon.net
  Subject: Re: timestamp
  In-Reply-To: <1033993509.311.17.camel@lerlaptop>

* 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