SELECT COUNT(id) FROM tableA WHERE DATE(getdate) = '2016-08-14'
getdate
GETDATE()
DECLARE @TheDate date = '20160814'; SELECT COUNT(id) FROM tableA WHERE getdate >= @TheDate AND getdate < DateAdd(day, 1, @TheDate);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)