Q&A for professional and enthusiast programmers
set statistics io on --select min(Id), max(Id) from Users --select min(Id), max(Id), count(*) from Users --select min(CreationDate), max(CreationDate), count(*) from Users select min(Id) from Users where year(CreationDate) = 2023 select min(Id) from Users where year(CreationDate) = 2022 select min(Id) from Users where year(CreationDate) = 2018 select min(Id) from Users where year(CreationDate) = 2017