QUERY PLAN "Nested Loop (cost=394.93..6477.86 rows=1 width=84)" " -> Nested Loop (cost=394.93..6472.10 rows=1 width=62)" " -> Hash Join (cost=394.93..6423.85 rows=8 width=70)" " Hash Cond: ((""outer"".snumber = ""inner"".snumber) AND (""outer"".event_id = ""inner"".event_id))" " -> Hash Join (cost=1.10..5822.46 rows=6916 width=54)" " Hash Cond: (""outer"".field_id = ""inner"".field_id)" " -> Seq Scan on seats (cost=0.00..4887.80 rows=172880 width=24)" " -> Hash (cost=1.08..1.08 rows=8 width=46)" " -> Seq Scan on fields (cost=0.00..1.08 rows=8 width=46)" " -> Hash (cost=393.63..393.63 rows=41 width=24)" " -> Index Scan using speed_3 on history (cost=0.00..393.63 rows=41 width=24)" " Index Cond: (type_id = 6)" " Filter: (undo_action_id > 0)" " -> Index Scan using i_action_id2 on actions (cost=0.00..6.02 rows=1 width=8)" " Index Cond: (""outer"".action_id = actions.action_id)" " Filter: (((created)::date = '2005-02-24'::date) AND (user_id = 23))" " -> Index Scan using events_pkey on events (cost=0.00..5.75 rows=1 width=46)" " Index Cond: (""outer"".event_id = events.event_id)"