distribute queries evenly