Month: August 2026

  • Reseed Identity – Can it Cause Clashes?

    Reseed Identity – Can it Cause Clashes?

    I recently had cause to reseed an identity column on a table in SQL Server, which got me wondering “If we reseed an identity column to a value lower than the existing identity values in the column, could it cause a clash?” Because why wouldn’t you wonder if you can cause something to break, whilst…

    Keep reading

  • I Was Today Years Old When…Stored Procedures – Optional String Quotes

    Today’s post is a quick one and the first in a new series I am calling “I Was Today Years Old When…” where I share simple little nuggets that I stumbled across where I think “How…HOW have I never known this” The series for me will serve as a reminder as to why I love…

    Keep reading

  • sp_executesql and Execution Plans

    sp_executesql and Execution Plans

    Last Updated: August 17, 2026 Whilst I would say the actual execution plan is the most useful, estimated execution plans have their place – sometimes you just need to see estimates or a quick verification that a change you have made has had some effect on plan shape. I find them helpful to quickly see…

    Keep reading

  • Setting up the Stack Overflow database in Postgres

    Setting up the Stack Overflow database in Postgres

    I’ve worked with Microsoft SQL Server for many years as well as dipping my toes into the MySQL world as and when required, however, I have not done as much with PostgreSQL. It’s hard to ignore the momentum that Postgres has built in recent years; it is moving up the Stack Overflow Developer Survey and…

    Keep reading

  • Curse of the Catch-All query

    Curse of the Catch-All query

    Last Updated: August 17, 2026 The catch-all query – a fairly common pattern that is often seen in SQL Server apps where there is a list of results that can be filtered by one or more criteria. This usually takes the form of a stored procedure that is constructed as below. The example stored procedure…

    Keep reading

  • OR predicates and Indexes

    OR predicates and Indexes

    Last Updated: August 4, 2026 In this post, we will look at how SQL Server accesses indexes when an OR predicate is used. For this demo, I am going to use the Stack Overflow Database. I am using the large 2024 version provided under cc-by-sa 4.0 licence from Stack Exchange Data Dump and running in…

    Keep reading

  • Four Flavours of Postgres Install – Part 4 (Windows)

    Four Flavours of Postgres Install – Part 4 (Windows)

    This post is the next in a short series exploring the different ways we can install a PostgreSQL server. This time, we’ll look at a vanilla install on Windows – no Docker involved. The VM I’ll use the same spec VM as in the last post, which is sufficient for demonstration purposes: Firstly, let’s hop…

    Keep reading

  • In a Query Plan Near You – Stats Loaded For Compilation

    In a Query Plan Near You – Stats Loaded For Compilation

    Last Updated: August 11, 2026 Something I have been making use of recently is the change in the way statistics that have been used to compile a plan are presented to us as SQL Server users. On a number of occasions I have needed to understand, or at least get some sense of, which statistics…

    Keep reading