Identifying HIPAA, PCI & SOX Data for Masking
Working for a company based in the UK (still currently a part of the EU) I had a lot of...
2018-08-15 (first published: 2018-07-30)
2,686 reads
Working for a company based in the UK (still currently a part of the EU) I had a lot of...
2018-08-15 (first published: 2018-07-30)
2,686 reads
Over the last 18 months or so, I’ve spent a lot of time reading about the General Data Protection Regulation or GDPR. If you don’t know about it, you live under a rock, are a very old school dba, here’s a reference to the law itself. If you’re working as a data professional, I’d strongly […]
2018-08-06
99 reads
I’ve posted a number of new videos to the Youtube channel that might be of interest if you’re a data...
2018-08-03
398 reads
Moving your database development, deployment and management into a DevOps methodology does involve choosing and implementing tools and tooling. Tools...
2018-07-25 (first published: 2018-07-16)
2,068 reads
In my previous Database Fundamentals post, I showed you how to use the Query Designer to build a query. That...
2018-07-23
827 reads
I schedule many of my blog posts at least 2-3 weeks out, so I have time to adjust them, change,...
2018-07-16 (first published: 2018-07-09)
3,812 reads
Last fall, Microsoft split the coding and release of SQL Server Management Studio away from any dependency on the server...
2018-07-12 (first published: 2018-07-05)
4,769 reads
Grant talks about the lessons of history when the goals of different groups don't align.
2018-07-09
88 reads
I have quite a few speaking engagements coming up. Rather than an intermittent blog post, I’ve decided to have a...
2018-07-04 (first published: 2018-06-25)
1,654 reads
I place a lot of emphasis on capturing actual execution plans because of the runtime metrics, but with Trace Flag...
2018-06-19 (first published: 2018-06-11)
1,803 reads
By Steve Jones
This is timely, as I’m currently on a boat in the Adriatic taking a...
You can find the slides and SQL scripts for my session “Spice up your...
By SQLPals
How to Clear the SSMS Cache (SSMS 21 and Later) Updated...
Comments posted to this topic are about the item Using CHOOSE()
Comments posted to this topic are about the item Re-Seeding a Broken Log Shipping...
Comments posted to this topic are about the item The DBA is Dead! Long...
We have this code that sets some status values and then queries them using the CHOOSE() function in SQL Server 2025.
CREATE TABLE Status
(
StatusID INT,
StatusDescription VARCHAR(20)
);
GO
INSERT dbo.Status
(
StatusID,
StatusDescription
)
VALUES
(0, 'Uncategorized'),
(1, 'Active'),
(2, 'Inactive'),
(3, 'Temp');
GO
SELECT CHOOSE(StatusID, 'Unknown', 'Active', 'Inactive', 'Temporary')
FROM Status;
When the SELECT runs, what is returned? See possible answers