Removed ORDER BY clause from allBuckets query, which possibly was causing unstable behaviour of ResultSet