RethinkDB: Case insensitive sort

You can easily sort RethinkDB results in a case-insensitive fashion, if you lower-case the result:

r.db('test')
 .table('users')
 .orderBy( x => x('user_name').downcase() )