Press "Enter" to skip to content

Day: August 4, 2026

Spurious Correlations: The CRAN Package

Mauricio Vargas Sepulveda has released an R package:

The goal of spuriouscorrelations is to keep alive the amazing examples from Tyler Vigen. Unfortunately, as of 2023-10-09, the website is down as my students noticed. Therefore, I decided to use the snapshot from the Internet Wayback Machine to save the datasets from 2023-06-07.

Click through to see how you can re-live those old charts, using the example of “number of people who drowned by falling into a pool” versus “films Nicolas Cage appeared in” on an annual basis. H/T R-Bloggers.

Leave a Comment

DOP Non-Feedback

Rebecca Lewis tries to get some feedback:

In my DOP Feedback post last month, I shared something very frustrating. I had all the documented prerequisites for DOP Feedback in place. Query Store in READ_WRITE mode, DOP_FEEDBACK enabled at the database scope, Compatibility Level 160, MAXDOP set to 14, and a repeatable workload generating real parallelism waits — but the DOP feedback never fired. No dop_feedback_eligible_query event. No entries in sys.query_store_plan_feedback. Nothing.

I said I’d follow with a sequel when I found a workload that does become eligible, and then I’d compare it against the one that did not. Well. This is that sequel, but I still don’t have it. Today is honestly my fourth full-day of testing without triggering any DOP Feedback.

Click through to learn what doesn’t work. Or at least didn’t work for Rebecca.

Leave a Comment

Executing Arbitrary Code during SQL Server Database Restoration

Fabiano Amorim explains a reason for the July SQL Server patch cycle:

CVE-2026-47295 is a SQL Server vulnerability that lets a maliciously crafted database backup execute attacker-controlled code with sysadmin privileges during a routine RESTORE DATABASE operation.

The flaw lives in the internal replication cleanup procedure sys.sp_MSremovedbreplication_internal, which builds a dynamic procedure name from the restored database’s name using QUOTENAME(). Because the destination variable is only nvarchar(255), a carefully crafted database name — one packed with closing square brackets — causes the generated name to be silently truncated into a different, attacker-controlled procedure name.

SQL Server then executes that procedure under an elevated internal restore context. The proof of concept detailed in this article demonstrates full instance compromise: a restored backup creates a new SQL Server login and adds it to the sysadmin fixed server role, with no application input, no visible SQL injection syntax, and no chance for an administrator to review the database first.

As mentioned in my lead-in, the July 2026 SQL Server patches fix this vulnerability, so it’d be a good idea to install that and then check out what you could do to an unpatched instance.

Leave a Comment

Viewing Statistics a SQL Server Query Used

Dualcore DBA takes a look:

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 SQL Server has used to come up with some of its estimates, usually when troubleshooting a poor estimate. This information has been available to us for a while, but up until fairly recent (OK – define recent, I guess!) versions of SQL Server, it was a bit hidden.

Granted, “fairly recent” means “all of the SQL Server versions that no longer have official support.” But there’s a compatibility level factor at play as well, so click through to learn more.

Leave a Comment

Checking Table Sizes in Microsoft Fabric Warehouses

Nikola Ilic wants to know how big that warehouse is:

If you’ve tried to check how much storage your Fabric warehouse tables consume, you’ve probably discovered that the usual SQL Server approaches don’t work. This post explains why, what else doesn’t work, and the one approach that does (and that I can use as a reference going forward, instead of wasting time and tokens asking LLMs).

Click through for the problem description and the answer. I completely agree with Nikola’s conclusion that it’s harder than it should be.

Leave a Comment