explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Agfi

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.000 50,670.172 ↓ 0.0 0 1

Update on judah.tickets tc (cost=13.03..855,717.04 rows=71,414 width=966) (actual time=50,670.172..50,670.172 rows=0 loops=1)

  • Buffers: shared hit=33,092 read=812,627
2.          

Initplan (for Update)

3. 0.015 0.015 ↑ 3.0 1 1

Seq Scan on judah.last_run (cost=0.00..13.03 rows=3 width=8) (actual time=0.015..0.015 rows=1 loops=1)

  • Output: last_run.last_run
  • Buffers: shared hit=13
4. 4.686 50,670.170 ↓ 0.0 0 1

Nested Loop (cost=0.00..855,704.01 rows=71,414 width=966) (actual time=50,670.170..50,670.170 rows=0 loops=1)

  • Output: tc.id, tc.number, tc.on_seal_number, tc.off_seal_number, tc.tank_id, tc.created_by, items.name, tc.stop_id, tc.stop_name, tc.route_id, tc.client_day, tc.nri, tc.operator, tc.ticket_date, tc.product, tc.disposition, tc.transporter, tc.load_time, tc.open_gauge_temperature, tc.close_gauge_temperature, tc.observed_temperature, tc.observed_gravity, tc.gross_volume_calculated, tc.gross_volume, tc.net_volume, tc.corrected_gravity, tc.open_gauge, tc.open_gauge_bbl, tc.close_gauge, tc.close_gauge_bbl, tc.ticket_volume, tc.trucking_co, tc.operating_co, tc.well_name, tc.start_time, tc.end_time, tc.volume_disposed, tc.water_source, tc.company_name, tc.lease_name, tc.lane_selection, tc.trucker_id, tc.driver_name, tc.field_ticket_no, tc.ctid, items.ctid
  • Join Filter: (tc.tank_id = items.id)
  • Buffers: shared hit=33,092 read=812,627
5. 50,665.484 50,665.484 ↑ 11.0 22,825 1

Seq Scan on judah.tickets tc (cost=0.00..848,179.48 rows=249,948 width=928) (actual time=26,937.881..50,665.484 rows=22,825 loops=1)

  • Output: tc.id, tc.number, tc.on_seal_number, tc.off_seal_number, tc.tank_id, tc.created_by, tc.stop_id, tc.stop_name, tc.route_id, tc.client_day, tc.nri, tc.operator, tc.ticket_date, tc.product, tc.disposition, tc.transporter, tc.load_time, tc.open_gauge_temperature, tc.close_gauge_temperature, tc.observed_temperature, tc.observed_gravity, tc.gross_volume_calculated, tc.gross_volume, tc.net_volume, tc.corrected_gravity, tc.open_gauge, tc.open_gauge_bbl, tc.close_gauge, tc.close_gauge_bbl, tc.ticket_volume, tc.trucking_co, tc.operating_co, tc.well_name, tc.start_time, tc.end_time, tc.volume_disposed, tc.water_source, tc.company_name, tc.lease_name, tc.lane_selection, tc.trucker_id, tc.driver_name, tc.field_ticket_no, tc.ctid
  • Buffers: shared hit=33,053 read=812,627
6. 0.000 0.000 ↓ 0.0 0 22,825

Materialize (cost=0.00..26.10 rows=2 width=44) (actual time=0.000..0.000 rows=0 loops=22,825)

  • Output: items.name, items.ctid, items.id
  • Buffers: shared hit=39
7. 0.049 0.049 ↓ 0.0 0 1

Seq Scan on judah.stg_items items (cost=0.00..26.09 rows=2 width=44) (actual time=0.049..0.049 rows=0 loops=1)

  • Output: items.name, items.ctid, items.id
  • Filter: (items.updated_at >= $0)
  • Rows Removed by Filter: 7
  • Buffers: shared hit=39