2017-07-10
900 reads
2017-07-10
900 reads
Derik Hammer sets out to disprove another pervasive performance myth : TRUNCATE is faster than DELETE because it isn't logged and can't be rolled back.
2017-06-01
4,663 reads
Guest author Derik Hammer dismisses the common myth that table variables perform better than temp tables because they are always in memory.
2017-05-11
5,730 reads
Aaron Bertrand begins a new series around disproving prevalent myths regarding SQL Server performance.
2017-04-13
4,686 reads
Greg Larsen explains how you can use Dynamic Management Objects and stored procedures to return your worst performing T-SQL statements.
2017-03-06
5,202 reads
Aaron Bertrand acknowledges that DISTINCT and GROUP BY are usually interchangeable, but shows there are cases where one performs better than the other.
2017-02-23
8,502 reads
Ben Snaidero explains that if you are updating your SQL Server table statistics nightly, but still seeing occasional poor performance with some of the queries being executed against my database, statistics could be the issue.
2017-02-09
4,089 reads
One way to improve SQL Server performance is to use as few resources as possible. In this post Rahul Mehta demonstrates how you can do this by disconnecting queries post-execution with a simple change in SSMS.
2016-12-21
5,620 reads
As an IT company, it is crucial that you maintain uptime and monitor the performance of various processes. By making database load balancing a key element, you can ensure that your processes and websites run smoothly. Tony Branson explains.
2016-11-24
5,719 reads
Erin Stellato (@erinstellato) looks into sparse columns in SQL Server – the changes to space requirements and the impact on the write portion of your workload.
2016-03-15
3,581 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 Risk Vs Reward, The never...
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...
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