LutzM (1/2/2014)
I don't think a simple DISTINCT will do it since it would return two rows ("Test." and "Test..") where one ("Test") is expected.Maybe one of the following approaches will work:
SELECT DISTINCT (LEFT(yourColumn,4)) FROM yourTable
SELECT DISTINCT (REPLACE(yourColumn,'.','')) FROM yourTable
But that's just guessing based on your sample data...
Dang... I thought the dots were just noise. This is why I wish people would provide data in a readily consumable format.
Before you make another post, please see the first link under "Helpful Links" in my signature line below. It helps eliminate confusion and increases the likelihood of you actually getting a correct answer to your problem and fairly quickly, too.
--Jeff Moden
Change is inevitable... Change for the better is not.