stats - refactored query to rely less on eager loading