March 30, 2006 at 9:32 am
The results you want are easily generated by three seperate distinct statements.
Select Distinct A From Table
Select Distinct B From Table
Select Distinct C From Table
Unless there is some relation between A, B, and C though, you won't be putting them into a single result. And it looks like there isn't by what you are asking. At the best, you could create a temp table, and insert the results of your disctinct statements into row 1, 2, 3, 4, 5, etc....giving you a single result having the columns with the distinct values, but not really usable in any manner other than three different columns of distinct values....
On another thought, why are these in the same table, if they are not related? It violates entity modeling, and proper table structure.
The reverse of this, deleting the dups could be accomplished by walking the table, and updating the values of previously found values to '' where rownumber is greater than the first occurrance....
Viewing post 1 (of 2 total)
You must be logged in to reply to this topic. Login to reply