Ver Mensaje Individual
  #2  
Antiguo 05-05-2008
Avatar de RONPABLO
[RONPABLO] RONPABLO is offline
Miembro Premium
 
Registrado: oct 2004
Posts: 1.514
Reputación: 21
RONPABLO Va por buen camino
Creo que Extract te regresa un valor entero, y al compararlo con fecha debe de ser un tipo Date, entonces la comparación debe ser:

Código SQL [-]
  Select folio, fecha from facturas
      where extract(DAY from fecha) between 
          extract(DAY from :fecha1) and extract(DAY from :fecha2)
ó

Código SQL [-]
  Select folio, fecha from facturas
      where fecha between :fecha1 and :fecha2
__________________
"Como pasa el tiempo..... ayer se escribe sin H y hoy con H"
Responder Con Cita