Fix queries under postgresql.

See https://code.djangoproject.com/ticket/23557

We don't care what order the results come in, so override default
sorting.

Change-Id: I1916e1b9975358e29529eb40ff1dd27ef89f6687