Short Circuiting Your Session
It isn’t very often that one would consider a short circuit to be a desired outcome. In SQL Server we...
2019-01-16 (first published: 2019-01-05)
2,071 reads
It isn’t very often that one would consider a short circuit to be a desired outcome. In SQL Server we...
2019-01-16 (first published: 2019-01-05)
2,071 reads
A magical thing happened this week in the SQL Community Slack (it’s free to join, by the way, sign up here). In the midst of a discussion about the...
2019-01-16
76 reads
We all have written queries that use COUNT DISTINCT to get the unique number of non-NULL values from a table....
2019-01-15 (first published: 2019-01-03)
2,485 reads
(2019-Jan-06) In the past, I used to always rely on shapefiles crafted by others to create my map visualizations in...
2019-01-15 (first published: 2019-01-06)
6,797 reads
Inspector V1.3 is now available on GitHub.
We have updated the sample report for you to play with which includes the...
2019-01-15
158 reads
You will very likely know that SQL Server 2008 / R2 end of support is on July 9th 2019. Not that...
2019-01-15
260 reads
Watch this week's video on YouTube
While most of us strive to make as few mistakes as possible when it comes to our servers and data, accidents do occasionally happen.
Sometimes...
2019-01-15
9 reads
Watch this week's video on YouTube
While most of us strive to make as few mistakes as possible when it comes to our servers and data, accidents do occasionally happen.
Sometimes...
2019-01-15
14 reads
In a previous post, I talked about some of the available storage options that can be used to back up...
2019-01-14 (first published: 2019-01-04)
448 reads
The Kessel Run Medal for 2019Hello Dear Reader, it's been a while since we talked. Part of the new year is setting goals. I plan to blog more. I...
2019-01-14
19 reads
By Steve Jones
Here are the resources for my talk at Day of Data Boston. Slides –...
By Steve Jones
I’ve covered the values in a number of previous posts on the Book of...
By Arun Sirpal
When the evidence names the database, it says so. When it doesn’t, it stops....
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