• While I agree its not a practical solution, as there are names (Yvonne, Pattinson, Lee, off the top of my head) where consecutive characters can be the same and so you will be destroying potentially valid names

    However, I can see its use as a test question in a technical interview for an SQL developer just to see how they think and solve a complex SQL problem.

    _________________________________________________________________________
    SSC Guide to Posting and Best Practices