I want to convert :
select convert(nvarchar(16), TimeLog, 120) requestTime,
count(Request) As noOfQueries
from LogData
where TimeLog between @StartDate and @EndDate
group by convert(nvarchar(16), TimeLog, 120) order by requestTime;
Here in the where clause the Timelog is between: 2012-06-21 and 2012-06-21 but I want it between 2012-06-21 00:00:00 and 2012-06-21 23:59:59
Hence I want to convert the @Satrtdate / @EndDate into above format so I would like to append 00:00:00 to @StartDate and 23:59:59 to @EndDate .