Work Habits
I enjoy woodworking as a hobby and as I try new things I find that my work habits during the...
2009-08-26
1,579 reads
I enjoy woodworking as a hobby and as I try new things I find that my work habits during the...
2009-08-26
1,579 reads
I’ve been reading his blog for a while and getting consistently good value. I’d categorize it as a SQL blog...
2009-08-25
724 reads
Last but certainly not least we’ve just announced Kalen Delaney as a member of the Advisory Council. Now that we...
2009-08-25
578 reads
I currently write the editorial for the PASS Connector which is published every two weeks as part of my role...
2009-08-25
551 reads
It’s been a busy few weeks since update #12. We announced guidelines for submitting content to sqlpass.org, an effort that...
2009-08-23
744 reads
I’ve touched on it some in the past, but it’s a question that comes up a lot when we discuss...
2009-08-21
2,360 reads
You’ve probably heard of Costco, one of those warehouse type stores that sells stuff in bulk. We buy stuff there...
2009-08-20
578 reads
Just announced at http://blog.sqlsaturday.com/2009/08/sqlsaturday-advisory-council-newest.html, Buck makes three – one more to go coming up soon!
2009-08-19
553 reads
I had a great call with John Sterrett last week about the possibility of having a SQLSaturday in Wheeling and...
2009-08-19
926 reads
Ran across this in a recent class while covering partitioning. Start by creating a standard partitioning function and the scheme,...
2009-08-19
2,504 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