explain.depesz.com

PostgreSQL's explain analyze made readable

Result: DPfL

Settings
# exclusive inclusive rows x rows loops node
1. 0.075 35,642.939 ↑ 1.0 256 1

Unique (cost=3,467,753.16..3,467,755.08 rows=256 width=52) (actual time=35,642.818..35,642.939 rows=256 loops=1)

2. 0.447 35,642.864 ↑ 1.0 256 1

Sort (cost=3,467,753.16..3,467,753.80 rows=256 width=52) (actual time=35,642.817..35,642.864 rows=256 loops=1)

  • Sort Key: q.eid, sp.date
  • Sort Method: quicksort Memory: 45kB
3. 1.163 35,642.417 ↑ 1.0 256 1

Nested Loop (cost=13,541.86..3,467,742.92 rows=256 width=52) (actual time=4.266..35,642.417 rows=256 loops=1)

4. 2.214 2.214 ↑ 1.0 256 1

Index Only Scan using all_equities_vw9_eid_only_idx on all_equities_vw9 q (cost=0.42..1,129.28 rows=256 width=8) (actual time=0.012..2.214 rows=256 loops=1)

  • Index Cond: (eid = ANY ('{1000000779,1000000780,1000000829,1000000835,1000000838,1000000902,1000000978,1000001000,1000001025,1000001319,1000001330,1000001374,1000001405,1000001448,1000001477,1000001525,1000001534,1000001561,1000001562,1000001634,1000001644,1000001657,1000001663,1000001687,1000001721,1000001735,1000001749,1000001750,1000001757,1000001774,1000001824,1000001906,1000001910,1000001944,1000001977,1000001993,1000001994,1000002001,1000002007,1000002020,1000002042,1000002060,1000002081,1000002099,1000002117,1000002141,1000002171,1000002290,1000002299,1000002360,1000002373,1000002388,1000002427,1000002429,1000002459,1000002484,1000002494,1000002515,1000002526,1000002529,1000002533,1000002540,1000002665,1000002667,1000002730,1000002731,1000002808,1000002810,1000002822,1000002827,1000002848,1000002852,1000002885,1000002919,1000002924,1000002932,1000002934,1000002938,1000002994,1000002996,1000003004,1000003045,1000003061,1000003131,1000003159,1000003237,1000003280,1000003399,1000003416,1000003588,1000003600,1000003652,1000003659,1000003682,1000003689,1000003711,1000003714,1000003731,1000003825,1000003892,1000003947,1000003962,1000003977,1000003981,1000004002,1000004080,1000004165,1000004505,1000004507,1000004511,1000004537,1000004547,1000004575,1000004760,1000004846,1000004894,1000004917,1000005011,1000005016,1000005027,1000005047,1000005085,1000005097,1000005119,1000005125,1000005231,1000005241,1000005279,1000005301,1000005329,1000005336,1000005357,1000005376,1000005387,1000005395,1000005396,1000005516,1000005518,1000005557,1000005571,1000005595,1000005598,1000005625,1000005649,1000005665,1000005689,1000005753,1000005811,1000005840,1000005845,1000005850,1000005876,1000005880,1000005896,1000005905,1000005915,1000005925,1000005930,1000005944,1000005970,1000006027,1000006057,1000006067,1000006083,1000006088,1000006122,1000006131,1000006180,1000006221,1000006245,1000006299,1000006307,1000006470,1000006472,1000006573,1000006577,1000006578,1000006583,1000006585,1000006591,1000006626,1000006642,1000006654,1000006675,1000006711,1000006716,1000006780,1000006796,1000006799,1000006825,1000006863,1000006864,1000006867,1000006892,1000006896,1000006966,1000007038,1000007059,1000007090,1000007106,1000007113,1000007120,1000007163,1000007264,1000007269,1000007283,1000007309,1000007327,1000007337,1000007341,1000007351,1000007360,1000007371,1000007411,1000007428,1000007447,1000007460,1000007469,1000007470,1000007485,1000007487,1000007536,1000007554,1000007624,1000007633,1000007649,1000007727,1000007743,1000007748,1000007767,1000007844,1000007872,1000007889,1000007914,1000007915,1000007934,1000007935,1000007940,1000008056,1000008113,1000008117,1000008156,1000008222,1000008239,1000008248,1000008254,1000008263,1000008265,1000008274,1000008294,1000008309,1000008411,1000008437,1000008464,1000008525,1000008528}'::bigint[]))
  • Heap Fetches: 0
5. 0.768 35,639.040 ↑ 1.0 1 256

Limit (cost=13,541.43..13,541.43 rows=1 width=44) (actual time=139.214..139.215 rows=1 loops=256)

6. 393.216 35,638.272 ↑ 980.0 1 256

Sort (cost=13,541.43..13,543.88 rows=980 width=44) (actual time=139.212..139.212 rows=1 loops=256)

  • Sort Key: sp.date DESC
  • Sort Method: top-N heapsort Memory: 25kB
7. 278.956 35,245.056 ↓ 6.9 6,736 256

Nested Loop (cost=85.29..13,536.53 rows=980 width=44) (actual time=7.513..137.676 rows=6,736 loops=256)

8. 2.048 2.048 ↑ 1.0 1 256

Index Scan using intriniomapping_vw2_eid_idx on intriniomapping_vw2 map (cost=0.29..8.31 rows=1 width=4) (actual time=0.006..0.008 rows=1 loops=256)

  • Index Cond: (eid = q.eid)
9. 33,037.710 34,964.052 ↓ 1.8 6,115 282

Bitmap Heap Scan on stock_prices sp (cost=85.00..13,493.37 rows=3,485 width=16) (actual time=7.328..123.986 rows=6,115 loops=282)

  • Recheck Cond: ((security_id = map.security_id) AND (date >= '1900-01-01'::date) AND (date <= '2019-08-31'::date))
  • Filter: (close IS NOT NULL)
  • Heap Blocks: exact=48,555
10. 1,926.342 1,926.342 ↓ 1.8 6,115 282

Bitmap Index Scan on stock_prices_security_id_date_idx (cost=0.00..84.13 rows=3,485 width=0) (actual time=6.831..6.831 rows=6,115 loops=282)

  • Index Cond: ((security_id = map.security_id) AND (date >= '1900-01-01'::date) AND (date <= '2019-08-31'::date))
Planning time : 8.775 ms
Execution time : 35,643.053 ms