Categories
SQL Server

The Halloween Problem and SQL Server

It’s not the usual time of year to think about Halloween, but listening to Erik Darling and Kendra Little recently on the Dear SQL DBA podcast they mentioned a completely new topic to me: Halloween protection. No, it doesn’t prevent horrors in your code, or shops putting out festive decorations in October. It’s actually much more interesting and thought it was worth […]

Categories
SQL

Understanding Return Types with ISNULL and COALESCE

Last week we looked at how expressions are evaluated with the ISNULL and COALESCE functions. Whilst we’re in the area it’s worth running through how data types are selected for them too. It might have implications with how you implement them. The way these functions choose which data type to return differs, so they aren’t direct swap outs for each other, […]

Categories
SQL

Understanding Expression Evaluation with ISNULL and COALESCE

When eliminating NULL values with SQL Server queries we typically reach for ISNULL or COALESCE to do the job. Generally speaking they’ll provide equivalent results, but they work in different ways. If you’re dealing with logic more complex than ISNULL(ColA, ColB) – for example using a function or subquery as part of the expression – then you might be in for a surprise. […]

Categories
T-SQL Tuesday

T-SQL Tuesday #193 – A Note to the Past and a Warning from the Future

This month’s invitation from Mike asks us to write a couple of notes – one to our past self, and one from our future self – focused on what we were concerned about, and what we should be concerned about. I love it, and it’s been itching away at me all week. So onto the messages. First from 2025 back to 2020 Andy […]

Categories
Azure Data Factory

Sending Emails from Data Factory Pipelines

Not all pipelines in Azure have native options for sending emails. The lucky Fabric folks have an Office 365 connection ready to rock. Data Factory and Synapse don’t have email capability built-in and need another option to send messages. So for everyone who wants more emails for their inbox rules to handle (delete), we’ll build and call […]