How to debug bad performing queries due to uneven data distribution