Re: [SQL] working with unix timestamp

2004-03-17 Thread Gary Stainburn
On Tuesday 16 March 2004 5:56 pm, Frank Finner wrote: > On Tue, 16 Mar 2004 16:54:18 + Gary Stainburn > <[EMAIL PROTECTED]> sat down, thought > > long and then wrote: > > Hi folks. > > > > I've got a last_updated field on my stock records of type timestamp. > > > > This last_updated field I get

Re: [SQL] working with unix timestamp

2004-03-16 Thread Tom Lane
Gary Stainburn <[EMAIL PROTECTED]> writes: > How can I insert the integer timestamp in $timestamp into my table? The "clean" way is select 'epoch'::timestamptz + * '1 second'::interval; for instance regression=# select 'epoch'::timestamptz + 1079459165 * '1 second'::interval; ?column?

Re: [SQL] working with unix timestamp

2004-03-16 Thread Frank Finner
On Tue, 16 Mar 2004 16:54:18 + Gary Stainburn <[EMAIL PROTECTED]> sat down, thought long and then wrote: > Hi folks. > > I've got a last_updated field on my stock records of type timestamp. > > This last_updated field I get using the perl code: > > my $timestamp=(stat "$localcsv/VehicleStoc

[SQL] working with unix timestamp

2004-03-16 Thread Gary Stainburn
Hi folks. I've got a last_updated field on my stock records of type timestamp. This last_updated field I get using the perl code: my $timestamp=(stat "$localcsv/VehicleStock.$data_suffix")[10]; How can I insert the integer timestamp in $timestamp into my table? -- Gary Stainburn This email