Simplified aggregation code for linked views example