Mert Özen Further With Every Line

Blog

Mert Özen's blog posts on software development, backend, frontend, and DevOps.

Series
4 posts found #sql-server-2025
Reading Older SQL Servers: Engine Evolution from 2016 to 2025 and a Compatibility Level Upgrade Strategy
Database PART 19

Reading Older SQL Servers: Engine Evolution from 2016 to 2025 and a Compatibility Level Upgrade Strategy

The engine version and the compatibility level are different things: in a database running at level 130 on SQL Server 2025, a table variable is still estimated at 1 row, an MSTVF at 100 rows, a scalar UDF is called 8,916 times and REGEXP_LIKE isn't recognized. A 2016 to 2025 feature table, Microsoft Lifecycle dates, and a real run of the flow: upgrade the engine at the old level, collect with Query Store, raise the level, force the plan on a regression.

8 Nov 2026 10 min 7
SQL Server 2025 Optimized Locking: TID Locking, Lock After Qualification and Behavior Changes
Database PART 13

SQL Server 2025 Optimized Locking: TID Locking, Lock After Qualification and Behavior Changes

With optimized locking on, a transaction that updates 1,000 rows holds a single XACT lock instead of 1,017 locks and never escalates; with RCSI also on, LAQ evaluates the UPDATE predicate on the last committed version without locks, removing blocking but possibly changing the result of some concurrent work. The ADR prerequisite, new LCK_M_S_XACT waits, hints that disable LAQ, xactlock in the deadlock graph and the 2019/2022 difference, with real measurements.

8 Nov 2026 10 min 8
What SQL Server 2025 Added to T-SQL: REGEXP Functions, the Native JSON Type, the || Operator, PRODUCT and CURRENT_DATE
Database PART 18

What SQL Server 2025 Added to T-SQL: REGEXP Functions, the Native JSON Type, the || Operator, PRODUCT and CURRENT_DATE

SQL Server 2025 brought RE2-based REGEXP_LIKE/REPLACE/SUBSTR/INSTR/COUNT/MATCHES/SPLIT_TO_TABLE, a native json type, JSON_ARRAYAGG/JSON_OBJECTAGG, the || operator, PRODUCT, CURRENT_DATE, UNISTR and BASE64. With real output we show regex ignoring collation, an index seek for an anchored pattern, the preview fuzzy functions, and REGEXP_LIKE requiring compatibility level 170.

8 Nov 2026 13 min 4
SQL Lab: Running SQL Server 2025 in Docker, the VS Code MSSQL Extension and the Bookstore Sample Database
Database PART 02

SQL Lab: Running SQL Server 2025 in Docker, the VS Code MSSQL Extension and the Bookstore Sample Database

We run SQL Server 2025 in Docker with the mcr.microsoft.com/mssql/server:2025-latest image, keeping the password in an environment variable and the data on a volume; connect with sqlcmd, the VS Code mssql extension and SSMS 22; and load the 10-table Bookstore database used throughout the series. Edition choice, Rosetta emulation on Apple Silicon and why TrustServerCertificate is for labs only are covered too.

8 Nov 2026 11 min 4
Blog Map