The blog of Andy M. Mallon

Databases, technology & the people behind them.

Notes from the work, the community, and everything in between.

Stop trying to shrink tempdb files

Every time someone shrinks a database, a kitten dies. Stop shrinking your tempdb data files I recently wrote about growing, shrinking, and removing tempdb files. In that article I explained that SQL Server won’t move a page that contains an internal worktable …

Continue reading

Redgate Streamed

Last week, I had the pleasure of participating in Redgate Streamed, a three-day virtual conference organized by my friends at Redgate. My session was Shortcuts from an impatient DBA–discussing a bunch of Management Studio tips & tricks for data professionals. …

Continue reading

When STRING_SPLIT() falls short

Aaron attempting a STONE_SPLIT at a recent curling competition. This morning, my friend Aaron Bertrand (blog|twitter) posted a plea for help with STRING_SPLIT() improvements. I'm very much in Aaron's corner on this, having written about the olden days myself. …

Continue reading

Blocking with OBJECT_NAME()

Doggos increase blog readership by 140%. 14/10. They are good doggos. As a DBA, you probably use the OBJECT_NAME() function quite a bit. I know I do. If you aren’t familiar with it, you can read the documentation if you want, but it’s a pretty straightforward …

Continue reading

How to create date buckets in T-SQL

I was fiddling around with some data, looking at making a quick aging report. I probably should have reached for Power BI Desktop, but sometimes I can be stubborn, and I wanted to get my T-SQL to work–if nothing else to figure out how to make it work.

Continue reading

Updates to the Data Blogger Resource Kit

Earlier this year, I published the first crack at a Data Blogger Resource Kit. When I initially created the kit, I wasn’t quite sure exactly what direction I would go with it. In the months since, I’ve started to get a better idea of where I want to go, and …

Continue reading

Supporting the LGBTQ #SQLFamily

I won’t be at PASS Summit this year, so unlike last year, I won’t be organizing an LGBTQ Meetup at PASS Summit. I’m hoping that even without the meetup, all my LGBTQ #SQLFamily friends will still get together for some fun and networking.

Continue reading

Why does ALTER let me DROP?

I was recently chatting with a coworker, discussing why there is no discrete DROP permission for tables, procedures, etc. The conversation actually came from a #SQLHelp question on SQL Slack that was asked along the lines of “What if I want to let a user …

Continue reading

Data Blogger Resource Kit

When I started out blogging 5 years ago, there was a lot that I didn’t know. I figured things out as I went. The FreeCon helped give me a giant push in the right direction. But there are some things that nobody ever tells you. While sitting in a coffee shop I …

Continue reading