Tag Archives: T-SQL

FIRST_VALUE vs. Min: #SQLNewBlogger

I had mentioned some new T-SQL functions for SQL Server 2022 and a commenter asked about the difference between Min() and First_value. This post looks at a few cases. Another post for me that is simple and hopefully serves as … Continue reading

Posted in Blog | Tagged , , | Comments Off on FIRST_VALUE vs. Min: #SQLNewBlogger

New SQL Server 2022 Functions

At the recent 2024 PASS Data Community Summit, I saw a lightning talk from Mikey Bronowski on the New T-SQL Functions in SQL Server 2022.  Before the talk, I made a joke with him that none of these were new … Continue reading

Posted in Editorial | Tagged , | 6 Comments

Rename a Database: #SQLNewBlogger

I had someone ask me how to rename a SQL Server database recently. They were doing some development work and wanted to rename databases to test an application. I thought I remembered, but in this post, I show I learned … Continue reading

Posted in Blog | Tagged , , | 1 Comment

Counting Groups with Window Functions: #SQLNewBlogger

I looked at row_number() in a previous post. Now I want to build on that and do some counting of rows with COUNT() and the OVER clause. I’ll show how this differs a bit from a normal aggregate. Another post … Continue reading

Posted in Blog | Tagged , , , | 1 Comment