fix #362. Limit should be enforced after the aggregation