SQLite Forum

Show duplicate rows sorted
Python.  Simply create a collation in Python.  It will be slow, but it will work.  Assuming you are using the sqlite3 wrapper you do something like this:

def UnicodeCollate(test1, test2):
    return 1 if test1 > test2 else -1 if test1 < test2 else 0

conn = sqlite3.connect(...)
conn.create_collation('unicode', UnicodeCollate)


Mutatis Mutandis for any other python wrapper that lets you define collation sequences.  You might have to "fiddle faddle" with your UnicodeCollation function to make sure the two parameters are actually unicode strings before doing the comparison or you might not get the results you want.