Clive Roberts
SQL Server DBA
- Website
- cliveroberts.net · all feeds from this site
- Feed URL
https://www.cliveroberts.net/feed/
Read it in your FeedListing reader
Or add to: Feedly Inoreader Raw feed
Latest posts
-
Finding Special Characters with PATINDEX
Applies to SQL Server 2019, 2022 and 2025. Sooner or later every DBA gets asked to find special characters in a column: the stray tab that breaks an export, the apostrophe that upsets a downstream system, or the “space” that isn’t really a space. On SQL Server 2019 and 2022 the…
-
SQL Server Installs Tested Before and After with dbatools and Pester
A dbatools SQL Server install wrapped in Pester tests: the server is proved ready before anything is installed, and the instance is proved configured afterwards. With a second data centre settings file and the bugs I fixed. The post SQL Server Installs Tested Before and After…
-
COUNT(*) vs COUNT(1) in SQL Server
Applies to SQL Server 2019, 2022 and 2025. COUNT(*) vs COUNT(1) is one of the oldest arguments in SQL Server, and it still comes up in code reviews. The short answer is that they do exactly the same work. The question that actually matters is what you’re counting: rows, or…
-
The T-SQL FORMAT Function
Applies to SQL Server 2019, 2022 and 2025. The T-SQL FORMAT function turns a number or date into a string laid out the way a particular country expects. I mostly use it for one job: showing money with the right currency symbol, thousands separator and decimal mark in a report or…
-
News: SQL Server 2022 SQLskills Blackbelt Credly badge now available
New from SQLskills on SQL Server 2022 SQLskills. As you may know, anyone who attends one of our courses or self-certifies that they’ve completed watching a purchased course can get a ‘certification badge’ that we issue via Credly/Acclaim (after someone requests them at…
-
The Table Value Constructor in SQL Server
Applies to SQL Server 2019, 2022 and 2025. The table value constructor is the VALUES clause that lets you write several rows in one statement: VALUES (1, 'a'), (2, 'b'), (3, 'c'). Most people meet it as the multi-row INSERT, but it’s more general than that. It builds a small…
-
CREATE PROCEDURE in SQL Server
Applies to SQL Server 2019, 2022 and 2025. CREATE PROCEDURE is one of the first statements anyone learns in T-SQL, and most of us stop thinking about it after that. It’s worth a second look, because the rules about batches, parameters and name resolution catch out experienced…
-
News: [Video] Office Hours: Back from the PASS Summit
New from Brent Ozar on Office Hours Back. I’m back from the annual PASS Data Community Summit, so let’s talk industry news before we dive into your 3 top-voted questions from https://pollgab.com/room/brento. Here’s what we covered: 00:00 Start 00:05 News: the vibe at the PASS…
-
The T-SQL AVG Function
Applies to SQL Server 2019, 2022 and 2025. The T-SQL AVG function looks like the simplest aggregate there is: add the values up, divide by how many there are. Most of the time it is. But it has one habit that catches people out in reports again and again: when you average an…
-
News: Black Friday Sale – Blackbelt for $399!
New from SQLskills on Black Friday Sale Blackbelt. It’s the time of year again where companies do crazy sales on the day after Thanksgiving in the US, and we’re doing the same – but starting on a bit early. All below details are also in our online shop,… Read the full article at…
-
Capacity Report: When Each Drive Will Be Full
How fast each SQL Server volume and database is growing, how many months until each drive is full, the per-server totals for the quarterly pack and file settings that make growth unpredictable. The post Capacity Report: When Each Drive Will Be Full first appeared on Clive…
-
SQL Server Security Report: Who Has sysadmin, and What Changed
Every sysadmin and high-privilege login on every SQL Server, what changed since the last run, weak and blank passwords, password policy, sa, and orphaned users with the fix for each. The post SQL Server Security Report: Who Has sysadmin, and What Changed first appeared on Clive…
-
SQL Server Patch Report: Every Instance Against Its Target Build
Each SQL Server instance's build, CU and KB against the build you've approved, out-of-support versions, availability group replicas on different builds and the monthly compliance figure. The post SQL Server Patch Report: Every Instance Against Its Target Build first appeared on…
-
Windows Patch Report: Did This Month’s Updates Land?
The independent check that Windows patching worked on every database server: last update, monthly build, pending reboots, unsupported Windows, exceptions and the compliance figure. The post Windows Patch Report: Did This Month’s Updates Land? first appeared on Clive Roberts .
-
Integrity Check Report: Proving CHECKDB Actually Ran
When every database last passed DBCC CHECKDB, whether the integrity jobs ran and succeeded, and any suspect pages, for every SQL Server in one report. The post Integrity Check Report: Proving CHECKDB Actually Ran first appeared on Clive Roberts .
-
News: Modernize your apps with Azure SQL Database Hyperscale
New from Microsoft SQL Server Blog on Azure SQL Database Hyperscale. Learn how Azure SQL Database Hyperscale brings scale, competitive economics, and AI to the apps you already run, and the ones you build next. The post Modernize your apps with Azure SQL Database Hyperscale…
-
News: Would Open-Sourcing Microsoft SQL Server Actually Fix Anything?
New from Brent Ozar on Would Open-Sourcing Microsoft SQL. At the PASS Summit last week in Seattle, I was having a discussion with a few people who’d moved on from managing SQL Server over to working with PostgreSQL. They were talking about the advantages of open source – and……
-
SQL Server Certificate Expiry
Applies to SQL Server 2019, 2022 and 2025. Every SQL Server certificate has an expiry date, whether or not you gave it one. What surprises people is how little SQL Server certificate expiry actually matters for most of what certificates do inside the database engine, and how…
-
News: Make Your Nightly ETL Faster with TABLOCKX
New from Brent Ozar on Nightly ETL Faster. Let’s say that every night you need to make a completely new copy of a table. Yes, you’ve heard that you’re supposed to detect & track changes, and that you should only be loading the deltas, but for your business… Read the full article…
-
@@SERVICENAME and the SQL Server Service Name
Applies to SQL Server 2019, 2022 and 2025. Every instance has a SQL Server service name, and @@SERVICENAME is the quick way to ask an instance what its name is from T-SQL. It’s a small function, but I use it in scripts that need to work the same way on default and named…