Ver Mensaje Individual
  #2 (permalink)  
Antiguo 26/01/2013, 12:06
ComprasDesdeCasa
 
Fecha de Ingreso: octubre-2008
Mensajes: 127
Antigüedad: 15 años, 7 meses
Puntos: 5
Respuesta: Comparar dos rangos de horas

Select
count(1)
from
Actividades
where
fecha = FECHA_QUE_QUIERES_TENER and
horaInicio between HORA_INICIO_QUE_QUIERES_TENER AND HORA_FINAL_QUE_QUIERES_TENER and
horaFinal between HORA_INICIO_QUE_QUIERES_TENER AND HORA_FINAL_QUE_QUIERES_TENER;

Saludos.