Free Training 24HOP
In my sessions, I always talk about how to build your skill set when you don’t have a budget for...
2018-04-18
551 reads
In my sessions, I always talk about how to build your skill set when you don’t have a budget for...
2018-04-18
551 reads
Sometimes as a newbie to SQL Server using SQL Server Management Studio (SSMS) you don’t know about the little gold...
2018-03-27
511 reads
When applying a new SQL Server cumulative update, hot fix, or upgrade SQL Server doesn’t always apply all the fixes...
2018-02-21
1,283 reads
One of my goals for 2018 is to expand the reach of my blog.
As a blogger starting out I had...
2018-02-14
327 reads
I am so thrilled to have the opportunity to expand my writing with my first Simple-Talk article posted. Simple- Talk is technical journal and...
2018-02-07
320 reads
Here is a quick blog to show you something I discovered that I didn’t know existed.
I was on a Skype...
2018-01-31
392 reads
Last week, I got the chance to give my I’m It Survival Tips for the Lone DBA in a webcast for the first...
2018-02-09 (first published: 2018-01-24)
1,656 reads
A few weeks ago, I wrote Part 1 and 2 of this series, which was a beginner’s guide to Always...
2018-01-17
788 reads
Awhile back, if you are on Twitter, you can probably recall my ranting about the 949 indexes I was reviewing....
2018-01-10
1,726 reads
One of the hardest things you can do as a blogger is to come up with a post topic. Do...
2017-12-20
354 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