Finding Locks on Tables
Recently I needed to find a stored procedure that was creating a lock on a table and updating the table regularly. So my starting point was the table name,...
2015-04-30
10 reads
Recently I needed to find a stored procedure that was creating a lock on a table and updating the table regularly. So my starting point was the table name,...
2015-04-30
10 reads
I had to do this recently and needed to look up the syntax as I couldn’t remember it. I don’t...
2015-04-29
1,402 reads
Reading Time: 1 minutesMany times the DBA is faced with the dilemma of granting excessive...
The post They Can Do What?...
2015-04-29
983 reads
I’ve only recently started to play with Powershell (PoSH) but even I’ve begun to discover what a huge number of...
2015-04-29
1,605 reads
The run-time metric gets all the love, and for good reason. It’s easily witnessed by end users and the one...
2015-04-29
1,057 reads
I’ve spend a good three days on and off working with the new “Microsoft” DataZen dashboard tool and I think...
2015-04-29
701 reads
I’ve spend a good three days on and off working with the new “Microsoft” DataZen dashboard tool and I think...
2015-04-29
1,411 reads
By Steve Bolton
…………Throughout this series of amateur mistutorials in using SQL Server to identify outliers, we have repeatedly seen that...
2015-04-29
2,450 reads
When working with a MySQL database as a source you may experience some unexpected results in your data extracts. Most of the...
2015-04-29
2,892 reads
Today’s blog will be the first in a multi-part series on replicating Excel functions in T-SQL, starting with HARMEAN, GEOMEAN...
2015-04-29
2,317 reads
By Steve Jones
I caught this interesting item over on Pinal Dave’s blog: Eleven Interview Questions that...
By Hemantgiri
I use color-coded connections in SSMS to distinguish Production, Pre-Production, UAT, and Development. But...
Comments posted to this topic are about the item Split Large Queries in Athena...
Comments posted to this topic are about the item Finding Trailing Spaces
I have some data in a SQL Server 2025 database. It looks like this for the dbo.Customer table:
CustomerID CustomerName PreferredName 1 Steve Steve 2 Andy Andy 3 Brian Brian 4 Allan Allan 5 Devin Devin 6 Steve Steve 7 Sally SallyI want to detect which names have a single trailing space. The CustomerName is a varchar() and the PreferredName is a CHAR(). Does this query detect the problem rows?
SELECT
CustomerID,
CustomerName,
PreferredName
FROM Customer
WHERE CustomerName <> RTRIM(CustomerName)
OR PreferredName <> RTRIM(PreferredName); See possible answers