---------- Mensaje reenviado ---------- De: ruben avila galindo <ruben2...@gmail.com> Fecha: 17 de noviembre de 2011 11:42 Asunto: Re: [pgsql-es-ayuda] ERROR Interval Para: Miguel Angel Hernandez Moreno <miguel.hdz....@gmail.com>
y lo curioso miguel es cuando lo uso en un store procedure no necesito hacerlo apesar q lo mando como argumento ahi mi dilema a q se debe create Function sch_valor(arg_fecha text) select * from tabla where fecha >=arg_fecha and fecha <=arg_fecha+ Interval '15 minute' Saludos Ruben PerĂº 2011/11/17 Miguel Angel Hernandez Moreno <miguel.hdz....@gmail.com> > falta hacer el cast de text a timestamp > > select '2011-11-16 11:15:00'::timestamp + INTERVAL '15 minute' > > > 2011/11/17 ruben avila galindo <ruben2...@gmail.com> > >> Hola cuando quiero hacer este proceso me arroja este error : >> >> ERROR: invalid input syntax for type interval: "2011-11-16 11:15:00" >> >> LINE 1: select '2011-11-16 11:15:00' + INTERVAL '15 minute' >> >> ^ >> >> >> select * from tabla where fecha >='2011-11-16 14:00:00' and fecha >> <='2011-11-16 14:00:00'+ Interval '15 minute' > > > > > -- > ISC Miguel Angel Hernandez Moreno > >