Re: > fechahora

From: Leonel Nunez <lnunez(at)enelserver(dot)com>
To: Xavier Puig <xpuig(at)innova7(dot)net>
Cc: pgsql-es-ayuda(at)postgresql(dot)org
Subject: Re: > fechahora
Date: 2005-12-28 17:38:20
Message-ID: 43B2CD8C.1010903@enelserver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

Xavier Puig wrote:

> fachahora(Timestamp with time zone)
> una vez insertada la guarda tipo:2005-12-28 14:48:31.484638+02
> y quiero hacer un select de las fechas superiores a 27-12-2005, o sea:
> select to_char(fechahora,'DD-MM-YYYY') from usuarios where
> to_char(fechahora,'DD-MM-YYYY') > '27-12-2005';

leonel=> set datestyle = German;
SET
leonel=> select to_char ( b, 'DD-MM-YYYY') from b where b > '23-12-2005';
to_char
------------
30-12-2005
31-12-2005
24-12-2005
25-12-2005
(4 rows)

> pero me devuelve
> 28-12-2005
> y también(esto no quiero)
> 28-11-2005
> 29-10-2005
> 28-10-2005
> .
> .
> .
> .
> como debo formatear las fechas?

http://www.postgresql.org/docs/8.1/interactive/functions-formatting.html

> gracias y feliz 2006
> xavi
>
> ---------------------------(fin del mensaje)---------------------------
> TIP 4: No hagas 'kill -9' a postmaster
>
>

Leonel

In response to

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Leonel Nunez 2005-12-28 17:40:58 Re: Como se pueden guardar imagenes..
Previous Message Jaime Casanova 2005-12-28 17:35:23 Re: > fechahora