always sorts by id so pagination is deterministic #3322 user specified s...

...orts have higher priority. I removed the distinct option becuase there should never be duplicate rows. If there somehow are duplicates I assume they should be displayed.