SQL Server Functions- An Introduction
SQL FUNCTION: -
Function in a database can be defined as the code segment consisting of a logical group of SQL...
2011-08-02
2,992 reads
SQL FUNCTION: -
Function in a database can be defined as the code segment consisting of a logical group of SQL...
2011-08-02
2,992 reads
If you haven’t visited the SQL Saturday website you should take a look. There are SEVEN events planned during September around...
2011-08-02
559 reads
Oh no you, you got the Could not load type ‘Microsoft.AnalysisServices.SharePoint.Integration.ReportGalleryView’ error!!! What to do now? Why did you get...
2011-08-02
1,068 reads
We recently ran into a case where connecting to a Windows Server 2003 server with SQL Server installed on it,...
2011-08-02
15,682 reads
Last month, I started using Meetup to schedule SQL Server Study Group events. The idea is to meet twice a...
2011-08-02
946 reads
This editorial I wrote ran on SQLServerCentral a couple weeks back and generated a lot of comments, and more than...
2011-08-02
305 reads
Are you tired of doing self joins, just to get the value of a column in the previus/subsequent row, or...
2011-08-02
1,724 reads
First day of the month and first Monday of the month. The list is coming out a bit late due...
2011-08-02
803 reads
We are recruiting panelists for a “Women in Technology” discussion at SQLSaturday Oregon. SQLSaturday is an all-day free training event...
2011-08-01
567 reads
Since it is August 1, 2011 (which is also my birthday), I thought it would be a good time to...
2011-08-01
1,042 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