2020-07-20
540 reads
2020-07-20
540 reads
2020-03-16
620 reads
Introduction A popular joke about DBAs and database backups goes like this. There are two types of DBAs: DBAs that do backups DBAs that will do backups The joke is only stating the obvious – lack of database backups might be the end of a DBA career and/or the supported business. Unfortunately, that joke fails […]
2020-01-07
10,389 reads
2019-12-05
953 reads
If you have a list of striped backup files, how can you find the latest backup set? Steve Jones uses dbatools and PowerShell to automate this process.
2019-10-03
2,667 reads
2019-09-05
640 reads
The basics are important, especially with regards to backup and restore in SQL Server.
2019-08-31
400 reads
2019-08-01
1,003 reads
2019-07-25
726 reads
2019-07-01
866 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