Fix order by with column order specified in the query
Fix test failures on jenkins due to delayed time calculation