Data Compare on Temporal Tables
I hadn't seen much talk on doing data comparisons on temporal tables, as they are a new feature. I went...
2016-11-02 (first published: 2016-10-28)
3,144 reads
I hadn't seen much talk on doing data comparisons on temporal tables, as they are a new feature. I went...
2016-11-02 (first published: 2016-10-28)
3,144 reads
Here's a quick snippet to get a listing of the database backups that last occurred on a server. Most solutions...
2016-10-31
953 reads
Here's a quick snippet to get a listing of the database backups that last occurred on a server. Most solutions...
2016-10-31
485 reads
I hadn't seen much talk on doing data comparisons on temporal tables, as they are a new feature. I went...
2016-10-28
558 reads
Registered Servers
I've used Central Management Server registered servers in SSMS for primarily one purpose, saving connections. 🙂 This is definitely not...
2016-10-24 (first published: 2016-10-16)
5,374 reads
Untrusted constraints can be found when you alter/drop foreign key relationships and then add them back without the proper syntax....
2016-10-22
1,253 reads
Untrusted constraints can be found when you alter/drop foreign key relationships and then add them back without the proper syntax.If...
2016-10-22
244 reads
Here's my personal tweaked settings for deploying Minionware's fantastic Reindex & Backup jobs. In the development environment, I wanted to have...
2016-10-18
595 reads
Here's my personal tweaked settings for deploying Minionware's fantastic Reindex & Backup jobs. In the development environment, I wanted to have...
2016-10-18
233 reads
Troubleshooting
I ran into an error: The target principal name is incorrect. Cannot generate SSPI context. (Microsoft SQL Server, Error: 0)
I...
2016-10-17
1,364 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