The Trade Deadline Must be Drawing Near
The Trade Deadline Must be Drawing Near
Okay, so there is no trade deadline in SQL Server like there is in...
2010-06-29
2,142 reads
The Trade Deadline Must be Drawing Near
Okay, so there is no trade deadline in SQL Server like there is in...
2010-06-29
2,142 reads
Error 25602 When Creating an Extended Events Session: a Security Risk
I came across an interesting issue recently when helping someone...
2010-06-23
3,626 reads
How Do I ... Get a List of Tables With Data Modifications in a Specific Timeframe?
There was a question on a...
2010-06-18
1,964 reads
Building HTML Emails With SQL Server and XML
I’ve written a lot of custom reports in my days that output data...
2010-06-15
62,794 reads
SQL Saturday #43 in the Books
Another great SQL Saturday is in the books!! I had submitted 2 sessions, but there...
2010-06-12
918 reads
Interesting Case of SSIS Failures
We had an interesting case of SSIS failures recently where the cause ended up being improved...
2010-06-10
1,078 reads
T-SQL Tuesday # 07: Walkthrough for Sysprep in SQL Server 2008 R2
This blog entry is participating in T-SQL Tuesday #007, hosted...
2010-06-08
4,940 reads
Taking a Medical Approach to Performance Troubleshooting
I find it difficult sometimes to explain to someone how to have a take...
2010-05-31
2,662 reads
Are you a DBA? You might Be!
On Twitter, people do a lot more than gossip and post messages about mundane,...
2010-05-29
2,522 reads
Study Tips for the SQL MCM Exams
I met the new rotation of the SQL Server Certified Master program on Friday....
2010-05-16
2,179 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