Just Check ALL the Boxes
Today I ran into something on a client server I unfortunately see too often. The DBA goes through the trouble...
2017-10-05 (first published: 2017-09-27)
1,670 reads
Today I ran into something on a client server I unfortunately see too often. The DBA goes through the trouble...
2017-10-05 (first published: 2017-09-27)
1,670 reads
OK So, I am doing some digging and peaking around again in SQL Server and came across a database option...
2017-09-27 (first published: 2017-09-20)
2,056 reads
Ever wander around SQL Server properties and wonder what these little check boxes turn on? I do, and I get...
2017-09-13
359 reads
Please, please, please Admins do not leave your default index fill factor at 0. This means you are telling SQL...
2017-09-18 (first published: 2017-09-06)
3,902 reads
Every once in a while, I like to take a moment and learn something new about the latest SQL Server...
2017-08-30
1,209 reads
How many of you check the amount of Virtual Log Files (VLFs) your transaction logs have?
Working as a consultant now,...
2017-09-07 (first published: 2017-08-23)
2,106 reads
Last week I started a multi-part series on Today I Learned (TIL) about Microsoft Azure. This is part two of...
2017-05-24
949 reads
I thought maybe it would be a good idea to start a multi-part series on Today I Learned (TIL) about...
2017-05-17
533 reads
I am honored to be a Guest Blogger at SQLPerformance.com. As a member of the SentryOne Product Advisory Council (PAC)...
2017-04-18
377 reads
I am ecstatic to say I have joined Denny Cherry and Associates Consulting.
Lone No More
I am happy, excited, and nostalgic...
2017-04-17
363 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