get a count of id for each month

arkiboys 9,386 Reputation points


I have a table which has daily datetimestamp and loginID

I would like to get a count of the LoginID for each month. How can I do this please?

Timestamp LoginId

2020-12-11T15:01:54.201000+00:00 B22

2020-12-11T15:32:36.403000+00:00 A5


Thank you

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,251 questions
{count} votes

0 additional answers

Sort by: Most helpful