T-SQL Tuesday #45 – Who’s Auditing My SSIS Packages?
It’s time once again for that monthly geek party again we like to call T-SQL Tuesday. T-SQL Tuesday #45 is...
2013-08-13
871 reads
It’s time once again for that monthly geek party again we like to call T-SQL Tuesday. T-SQL Tuesday #45 is...
2013-08-13
871 reads
I recently encountered a DBCC CHECKDB failure with a fairly non-specific failure message. The error message said it terminated abnormally...
2013-07-24
7,240 reads
Lately, I’ve been finding more and more reasons to look in the transaction log for investigative purposes. Questions come up...
2013-05-27
1,210 reads
A little more than a year ago while working at Idera, I was consulted on reports from a few clients...
2013-05-21
1,229 reads
It’s time for that monthly geek party again we like to call T-SQL Tuesday. T-SQL Tuesday is one of the...
2013-04-09
1,158 reads
A network pipeline isn’t nearly as pleasant to look at as the oil pipeline (or anything) in Alaska, but it’s...
2013-03-27
3,287 reads
It has been a long journey to the final day my 31 Days of Disaster Recovery series, but we have...
2013-03-28 (first published: 2013-03-25)
2,436 reads
It’s been a tough and long road to 31 Days of Disaster Recovery. It’s been very difficult coming up with...
2013-03-12
1,349 reads
I am currently going through the process of looking for a new opportunity for my career. I’m going through the...
2013-03-08 (first published: 2013-03-01)
6,053 reads
For day 29 of my 31 Days of Disaster Recover series, I want to talk about restoring replicated databases from...
2013-02-25
1,369 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