Case Insensitive Sort with SQLObject

Submitted by jeff on Wed, 01/20/2010 - 19:08.

The key to case-insensitive search is to sort by the lowercase or uppercase of the sorting column.

SELECT * FROM songs ORDER BY lower(name)


from sqlobject.sqlbuilder import func
print list(Songs.select(orderBy=func.lower(Songs.q.name)))

Post new comment

The content of this field is kept private and will not be shown publicly.
CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
* five = 20
Solve this math question and enter the solution with digits. E.g. for "two plus four = ?" enter "6".