2017-07-06
3,083 reads
2017-07-06
3,083 reads
I just read several more horror stories that include, among other things, failed backups. I’ve said it before (at volume,...
2017-06-26 (first published: 2017-06-19)
1,824 reads
Thank you to everyone who participated in T-SQL Tuesday #091 which was on databases and DevOps. As I anticipated, this...
2017-06-23 (first published: 2017-06-15)
1,724 reads
It’s worth noting that a lot of people will never need to create their own database. You may never create...
2017-06-20
495 reads
One of my favorite things about being a technologist is constantly learning new things, but, this can lead us to...
2017-06-15 (first published: 2017-05-31)
2,794 reads
The hardest part about implementing DevOps is not the tools you choose, but the processes you use to make DevOps...
2017-06-13
1,141 reads
The best way to learn any software is to start using it. There are a bunch of software tools in...
2017-06-12
1,131 reads
Implementing DevOps with databases presents a unique set of challenges. However, just because something might be hard doesn’t mean that...
2017-06-06
429 reads
To get started with SQL Server, you need to install it. However, I’m not going to teach you how to...
2017-06-05
538 reads
I don’t doubt for a minute that on a certain level you’re sick to death of people talking about the Wanna Cry ransomware. However, bear with me, we need to go through it just a little more because it actually has some bearing on us as data professionals. OK, more than some bearing, it’s a […]
2017-06-05
203 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