explain.depesz.com

PostgreSQL's explain analyze made readable

Result: dUba

Settings
# exclusive inclusive rows x rows loops node
1. 0.007 36,436.989 ↓ 0.0 0 1

Append (cost=0.43..91,701.25 rows=3 width=43) (actual time=36,436.989..36,436.989 rows=0 loops=1)

2. 9,953.071 9,953.071 ↓ 0.0 0 1

Index Scan using customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p0_last_seen_idx on customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p0 (cost=0.43..30,596.91 rows=1 width=43) (actual time=9,953.071..9,953.071 rows=0 loops=1)

  • Index Cond: (last_seen > (now() - '14 days'::interval))
  • Filter: ((user_last_msg_received IS NOT NULL) AND (last_seen < last_message_creation_time) AND ((chat_platform_id)::text = 'whatsapp'::text) AND (last_message_creation_time >= (now() - '24:00:00'::interval)) AND (last_message_creation_time <= (now() - '26:00:00'::interval)) AND ((((user_last_msg_received)::bigint * 1000))::double precision < date_part('epoch'::text, last_message_creation_time)) AND (floor((date_part('epoch'::text, last_message_creation_time) - (((user_last_msg_received)::bigint * 1000))::double precision)) > '86400'::double precision))
  • Rows Removed by Filter: 30988
3. 13,350.017 13,350.017 ↓ 0.0 0 1

Index Scan using customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p1_last_seen_idx on customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p1 (cost=0.43..30,809.63 rows=1 width=43) (actual time=13,350.017..13,350.017 rows=0 loops=1)

  • Index Cond: (last_seen > (now() - '14 days'::interval))
  • Filter: ((user_last_msg_received IS NOT NULL) AND (last_seen < last_message_creation_time) AND ((chat_platform_id)::text = 'whatsapp'::text) AND (last_message_creation_time >= (now() - '24:00:00'::interval)) AND (last_message_creation_time <= (now() - '26:00:00'::interval)) AND ((((user_last_msg_received)::bigint * 1000))::double precision < date_part('epoch'::text, last_message_creation_time)) AND (floor((date_part('epoch'::text, last_message_creation_time) - (((user_last_msg_received)::bigint * 1000))::double precision)) > '86400'::double precision))
  • Rows Removed by Filter: 30957
4. 13,133.894 13,133.894 ↓ 0.0 0 1

Index Scan using customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p2_last_seen_idx on customers_on_plbwx5xygq2b3gp7in8q_partitioned2_p2 (cost=0.43..30,294.70 rows=1 width=43) (actual time=13,133.894..13,133.894 rows=0 loops=1)

  • Index Cond: (last_seen > (now() - '14 days'::interval))
  • Filter: ((user_last_msg_received IS NOT NULL) AND (last_seen < last_message_creation_time) AND ((chat_platform_id)::text = 'whatsapp'::text) AND (last_message_creation_time >= (now() - '24:00:00'::interval)) AND (last_message_creation_time <= (now() - '26:00:00'::interval)) AND ((((user_last_msg_received)::bigint * 1000))::double precision < date_part('epoch'::text, last_message_creation_time)) AND (floor((date_part('epoch'::text, last_message_creation_time) - (((user_last_msg_received)::bigint * 1000))::double precision)) > '86400'::double precision))
  • Rows Removed by Filter: 30991
Planning time : 3.663 ms
Execution time : 36,437.191 ms