Quoting Tom Lane <[EMAIL PROTECTED]>:
> Martin Marques <[EMAIL PROTECTED]> writes:
> > Look deeper into what Christopher said and use casting to get the right
> > output:
> > prueba=> select now()::timestamp(0);
>
> There's also "current_timestamp(0)", which is a more standards-compliant
> way of doing the same thing.
Didn�t know that existed. :-)
Anyway, my observation was not on the now() function, but at the casting. He
wants the output of th select over a timestamp field to come out without the
milliseconds, which is done with the casting.
Now, seeing your mail I realize that what he may want is this:
CREATE TABLE table_name (
.....
time_field timestamp(0)
);
Remember you will lose those milliseconds for ever with this table definition.
--
Porqu� usar una base de datos relacional cualquiera,
si pod�s usar PostgreSQL?
-----------------------------------------------------------------
Mart�n Marqu�s | [EMAIL PROTECTED]
Programador, Administrador, DBA | Centro de Telematica
Universidad Nacional
del Litoral
-----------------------------------------------------------------
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster