Select query problem for dates between different ranges
hi,
I am getting problem while selecting records for below mentioned query.
Select Min(TotalAvalablity) as TotalAvalablity from htl_FDRoomAvailability where REPLACE(CONVERT(varchar(50),ReserveDate, 101), ' ', '-')>='12/31/2009' and REPLACE(CONVERT(varchar(50),ReserveDate, 101), ' ', '-')<='01/01/2010'
Please any one help me why its showing null.If ReserveDate is between same year then its giving correct result.
Thanks,
Soumya