Risky Behavior
An interesting debate from one of my editorials on risk. Some great points raised by everyone, but I still think...
2007-08-07
605 reads
An interesting debate from one of my editorials on risk. Some great points raised by everyone, but I still think...
2007-08-07
605 reads
This was fun to write. It's a subject I'm passionate about and that too few in our field seem to...
2007-08-07
552 reads
We've dropped an acronym!
In my rounds of the blogs today, a number of people have pointed out that SQL Server...
2007-08-03
544 reads
Big news here in Orlando is that Joe Celko will be presenting two sessions at SQLSaturday on Nov 10. Once...
2007-08-02
480 reads
The article went live earlier this week. Didn't quite accomplish what I had hoped I think, which was to point...
2007-08-02
462 reads
I'm downloading now, and you need some sort of inviation to do so, but it's available and ready for you...
2007-08-01
619 reads
Q I need an easy way to see if a delete transaction has fired a trigger. Do you have any...
2007-08-01
639 reads
"Database Professional Toolkit" with Brian and Jeremy
Midlands PASS Chapter - August 2, 2007 Meeting
Sponsored by Red Gate Software
The Midlands PASS Chapter...
2007-07-31
1,568 reads
We've just moved all the PASS chapters that were hosted on ~.ssc.com domains over to ~.sqlgroups.com. This is part of...
2007-07-27
1,573 reads
If you're a Microsoft MVP, ApexSQL has brought back their industry experts program. You can find out more about it...
2007-07-25
1,744 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