I am used to oracle and now been thrown T-SQL, I am doing a course shortly but can you help out until then.
I have a list that I need to group in minutes.
Sample of rowdate data
SELECT ROWDATE,count(rowdate)
FROM [mydb].[dbo].[mytable]
GROUP BY ROWDATE
order by 1
2010-08-16 15:01:18.110 1
2010-08-16 15:01:18.203 1
2010-08-16 15:01:18.377 1
2010-08-16 15:01:18.453 1
2010-08-16 15:01:18.530 1
2010-08-16 15:01:18.610 1
2010-08-16 15:01:18.703 1
2010-08-16 15:01:18.813 1
2010-08-16 15:01:18.953 1
2010-08-16 15:01:19.173 1
2010-08-16 15:01:19.360 1
2010-08-16 15:01:19.483 1
2010-08-16 15:01:19.593 1
2010-08-16 15:01:19.673 1
2010-08-16 15:01:19.733 1
2010-08-16 15:01:19.813 1
2010-08-16 15:01:19.890 1
2010-08-16 15:01:19.970 1
2010-08-16 15:01:20.047 1
I just want to group by mins.
SELECT to_char(rowdate,'dd/MM/yyyy HH24:MI'),count(rowdate)
FROM mytable
GROUP BY to_char(rowdate,'dd/MM/yyyy HH24:MI')
order by 1
On sql server(T-SQL) what would be the equivalent script?