Our SQL Server UserLogins table has these columns: UserID, DateTime, IpAddress.

How can I select rows of users who have logged in from more than three different ip addresses within a specified time period (e.g., one month), ordered by User ID