explain.depesz.com

PostgreSQL's explain analyze made readable

Result: A6lR

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Limit (cost=102,108.64..105,779.35 rows=100 width=355) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Result (cost=102,108.64..215,937.36 rows=3,101 width=355) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Sort (cost=102,108.64..102,116.40 rows=3,101 width=291) (actual rows= loops=)

  • Sort Key: (timezone('UTC'::text, t.update_date)) DESC
4. 0.000 0.000 ↓ 0.0

WindowAgg (cost=101,889.34..101,990.13 rows=3,101 width=291) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Sort (cost=101,889.34..101,897.10 rows=3,101 width=192) (actual rows= loops=)

  • Sort Key: t.creation_date DESC
6. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=8,584.71..101,709.51 rows=3,101 width=192) (actual rows= loops=)

  • Join Filter: (ad.terminal_id = t.id)
7. 0.000 0.000 ↓ 0.0

Gather (cost=1,048.74..94,127.01 rows=3,101 width=192) (actual rows= loops=)

  • Workers Planned: 2
8. 0.000 0.000 ↓ 0.0

Hash Join (cost=48.74..92,816.91 rows=1,292 width=192) (actual rows= loops=)

  • Hash Cond: (t.park_id = pa.id)
9. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on terminals t (cost=0.00..92,735.87 rows=5,168 width=165) (actual rows= loops=)

  • Filter: (domiciliation ~ ANY ('{5571212,5571211,5571210,5571209,5571208,5571207,5571206,5571205,5571204,5571203,5571202,5571201,5571200,5571199,5571198,5571197,5571196,5571195,5571194,5571193,5571192,5571191,5571190,5571189,5571188,5571187,5571186,5571185,5571184,5571183,5571182,5571181,5571180,5571179,5571178,5571177,5571176,5571175,5571174,5571173,5571172,5571171,5571170,5571169,5571168,5571167,5571166,5571165,5571164,5571163,5571162,5571161,5571160,5571159,5571158,5571157,5571156,5571155,5571154,5571153,5571152,5571151,5571150,5571149,5571148,5571147,5571146,5571145,5571144,5571143,5571142,5571141,5571140,5571139,5571138,5571137,5571136,5571135,5571134,5571133,5571132,5571131,5571130,5571129,5571128,5571127,5571126,5571125,5571124,5571123,5571122,5571121,5571120,5571119,5571118,5571117,5571116,5571115,5571114,5571113,5571112,5571111,5571110,5571109,5571108,5571107,5571106,5571105,5571104,5571103,5571102,5571101,5571100,5571099,5571098,5571097,5571096,5571095,5571094,5571093,5571092,5571091,5571090,5571089,5571088,5571087,5571086,5571085,5571084,5571083,5571082,5571081,5571080,5571079,5571078,5571077,5571076,5571075,5571074,5571073,5571072,5571071,5571070,5571069,5571068,5571067,5571066,5571065,5571064,5571063,5571062,5571061,5571060,5571059,5571058,5571057,5571056,5571055,5571054,5571053,5571052,5571051,5571050,5571049,5571048,5571047,5571046,5571045,5571044,5571043,5571042,5571041,5571040,5571039,5571038,5571037,5571036,5571035,5571034,5571033,5571032,5571031,5571030,5571029,5571028,5571027,5571026,5571025,5571024,5571023,5571022,5571021,5571020,5571019,5571018,5571017,5571016,5571015,5571014,5571013,5571012,5571011,5571010,5571009,5571008,5571007,5571006,5571005,5571004,5571003,5571002,5571001,5571000,5570999,5570998,5570997,5570996,5570995,5570994,5570993,5570992,5570991,5570990,5570989,5570988,5570987,5570986,5570985,5570984,5570983,5570982,5570981,5570980,5570979,5570978,5570977,5570976,5570975,5570974,5570973,5570972,5570971,5570970,5570969,5570968,5570967,5570966,5570965,5570964,5570963,5570962,5570961,5570960,5570959,5570958,5570957,5570956,5570955,5570954,5570953,5570952,5570951,5570950,5570949,5570948,5570947,5570946,5570945,5570944,5570943,5570942,5570941,5570940,5570939,5570938,5570937,5570936,5570935,5570934,5570933,5570932,5570931,5570930,5570929,5570928,5570927,5570926,5570925,5570924,5570923,5570922,5570921,5570920,5570919,5570918,5570917,5570916,5570915,5570914,5570913,5570912,5570911,5570910,5570909,5570908,5570907,5570906,5570905,5570904,5570903,5570902,5570901,5570900,5570899,5570898,5570897,5570896,5570895,5570894,5570893,5570892,5570891,5570890,5570889,5570888,5570887,5570886,5570885,5570884,5570883,5570882,5570881,5570880,5570879,5570878,5570877,5570876,5570875,5570874,5570873,5570872,5570871,5570870,5570869,5570868,5570867,5570866,5570865,5570864,5570863,5570862,5570861,5570860,5570859,5570858,5570857,5570856,5570855,5570854,5570853,5570852,5570851,5570850,5570849,5570848,5570847,5570846,5570845,5570844,5570843,5570842,5570841,5570840,5570839,5570838,5570837,5570836,5570835,5570834,5570833,5570832,5570831,5570830,5570829,5570828,5570827,5570826,5570825,5570824,5570823,5570822,5570821,5570820,5570819,5570818,5570817,5570816,5570815,5570814,5570813,5570812,5570811,5570810,5570809,5570808,5570807,5570806,5570805,5570804,5570803,5570802,5570801,5570800,5570799,5570798,5570797,5570796,5570795,5570794,5570793,5570792,5570791,5570790,5570789,5570788,5570787,5570786,5570785,5570784,5570783,5570782,5570781,5570780,5570779,5570778,5570777,5570776,5570775,5570774,5570773,5570772,5570771,5570770,5570769,5570768,5570767,5570766,5570765,5570764,5570763,5570762,5570761,5570760,5570759,5570758,5570757,5570756,5570755,5570754,5570753,5570752,5570751,5570750,5570749,5570748,5570747,5570746,5570745,5570744,5570743,5570742,5570741,5570740,5570739,5570738,5570737,5570736,5570735,5570734,5570733,5570732,5570731,5570730,5570729,5570728,5570727,5570726,5570725,5570724,5570723,5570722,5570721,5570720,5570719,5570718,5570717,5570716,5570715,5570714,5570713,5570712,5570711,5570710,5570709,5570708,5570707,5570706,5570705,5570704,5570703,5570702,5570701,5570700,5570699,5570698,5570697,5570696,5570695,5570694,5570693,5570692,5570691,5570690,5570689,5570688,5570687,5570686,5570685,5570684,5570683,5570682,5570681,5570680,5570679,5570678,5570677,5570676,5570675,5570674,5570673,5570672,5570671,5570670,5570669,5570668,5570667,5570666,5570665,5570664,5570663,5570662,5570661,5570660,5570659,5570658,5570657,5570656,5570655,5570654,5570653,5570652,5570651,5570650,5570649,5570648,5570647,5570646,5570645,5570644,5570643,5570642,5570641,5570640,5570639,5570638,5570637,5570636,5570635,5570634,5570633,5570632,5570631,5570630,5570629,5570628,5570627,5570626,5570625,5570624,5570623,5570622,5570621,5570620,5570619,5570618,5570617,5570616,5570615,5570614,5570613,5570612,5570611,5570610,5570609,5570608,5570607,5570606,5570605,5570604,5570603,5570602,5570601,5570600,5570599,5570598,5570597,5570596,5570595,5570594,5570593,5570592,5570591,5570590,5570589,5570588,5570587,5570586,5570585,5570584,5570583,5570582,5570581,5570580,5570579,5570578,5570577,5570576,5570575,5570574,5570573,5570572,5570571,5570570,5570569,5570568,5570567,5570566,5570565,5570564,5570563,5570562,5570561,5570560,5570559,5570558,5570557,5570556,5570555,5570554,5570553,5570552,5570551,5570550,5570549,5570548,5570547,5570546,5570545,5570544,5570543,5570542,5570541,5570540,5570539,5570538,5570537,5570536,5570535,5570534,5570533,5570532,5570531,5570530,5570529,5570528,5570527,5570526,5570525,5570524,5570523,5570522,5570521,5570520,5570519,5570518,5570517,5570516,5570515,5570514,5570513,5570512,5570511,5570510,5570509,5570508,5570507,5570506,5570505,5570504,5570503,5570502,5570501,5570500,5570499,5570498,5570497,5570496,5570495,5570494,5570493,5570492,5570491,5570490,5570489,5570488,5570487,5570486,5570485,5570484,5570483,5570482,5570481,5570480,5570479,5570478,5570477,5570476,5570475,5570474,5570473,5570472,5570471,5570470,5570469,5570468,5570467,5570466,5570465,5570464,5570463,5570462,5570461,5570460,5570459,5570458,5570457,5570456,5570455,5570454,5570453,5570452,5570451,5570450,5570449,5570448,5570447,5570446,5570445,5570444,5570443,5570442,5570441,5570440,5570439,5570438,5570437,5570436,5570435,5570434,5570433,5570432,5570431,5570430,5570429,5570428,5570427,5570426,5570425,5570424,5570423,5570422,5570421,5570420,5570419,5570418,5570417,5570416,5570415,5570414,5570413,5570412,5570411,5570410,5570409,5570408,5570407,5570406,5570405,5570404,5570403,5570402,5570401,5570400,5570399,5570398,5570397,5570396,5570395,5570394,5570393,5570392,5570391,5570390,5570389,5570388,5570387,5570386,5570385,5570384,5570383,5570382,5570381,5570380,5570379,5570378,5570377,5570376,5570375,5570374,5570373,5570372,5570371,5570370,5570369,5570368,5570367,5570366,5570365,5570364,5570363,5570362,5570361,5570360,5570359,5570358,5570357,5570356,5570355,5570354,5570353,5570352,5570351,5570350,5570349,5570348,5570347,5570346,5570345,5570344,5570343,5570342,5570341,5570340,5570339,5570338,5570337,5570336,5570335,5570334,5570333,5570332,5570331,5570330,5570329,5570328,5570327,5570326,5570325,5570324,5570323,5570322,5570321,5570320,5570319,5570318,5570317,5570316,5570315,5570314,5570313,5570312,5570311,5570310,5570309,5570308,5570307,5570306,5570305,5570304,5570303,5570302,5570301,5570300,5570299,5570298,5570297,5570296,5570295,5570294,5570293,5570292,5570291,5570290,5570289,5570288,5570287,5570286,5570285,5570284,5570283,5570282,5570281,5570280,5570279,5570278,5570277,5570276,5570275,5570274,5570273,5570272,5570271,5570270,5570269,5570268,5570267,5570266,5570265,5570264,5570263,5570262,5570261,5570260,5570259,5570258,5570257,5570256,5570255,5570254,5570253,5570252,5570251,5570250,5570249,5570248,5570247,5570246,5570245,5570244,5570243,5570242,5570241,5570240,5570239,5570238,5570237,5570236,5570235,5570234,5570233,5570232,5570231,5570230,5570229,5570228,5570227,5570226,5570225,5570224,5570223,5570222,5570221,5570220,5570219,5570218,5570217,5570216,5570215,5570214,5570213,5570212,5570211,5570210,5570209,5570208,5570207,5570206,5570205,5570204,5570203,5570202,5570201,5570200,5570199,5570198,5570197,5570196,5570195,5570194,5570193,5570192,5570191,5570190,5570189,5570188,5570187,5570186,5570185,5570184,5570183,5570182,5570181,5570180,5570179,5570178,5570177,5570176,5570175,5570174,5570173,5570172,5570171,5570170,5570169,5570168,5570167,5570166,5570165,5570164,5570163,5570162,5570161,5570160,5570159,5570158,5570157,5570156,5570155,5570154,5570153,5570152,5570151,5570150,5570149,5570148,5570147,5570146,5570145,5570144,5570143,5570142,5570141,5570140,5570139,5570138,5570137,5570136,5570135,5570134,5570133,5570132,5570131,5570130,5570129,5570128,5570127,5570126,5570125,5570124,5570123,5570122,5570121,5570120,5570119,5570118,5570117,5570116,5570115,5570114,5570113,5570112,5570111,5570110,5570109,5570108,5570107,5570106,5570105,5570104,5570103,5570102,5570101,5570100,5570099,5570098,5570097,5570096,5570095,5570094,5570093,5570092,5570091,5570090,5570089,5570088,5570087,5570086,5570085,5570084,5570083,5570082,5570081,5570080,5570079,5570078,5570077,5570076,5570075,5570074,5570073,5570072,5570071,5570070,5570069,5570068,5570067,5570066,5570065,5570064,5570063,5570062,5570061,5570060,5570059,5570058,5570057,5570056,5570055,5570054,5570053,5570052,5570051,5570050,5570049,5570048,5570047,5570046,5570045,5570044,5570043,5570042,5570041,5570040,5570039,5570038,5570037,5570036,5570035,5570034,5570033,5570032,5570031,5570030,5570029,5570028,5570027,5570026,5570025,5570024,5570023,5570022,5570021,5570020,5570019,5570018,5570017,5570016,5570015,5570014,5570013,5570012,5570011,5570010,5570009,5570008,5570007,5570006,5570005,5570004,5570003,5570002,5570001,5570000,5569999,5569998,5569997,5569996,5569995,5569994,5569993,5569992,5569991,5569990,5569989,5569988,5569987,5569986,5569985,5569984,5569983,5569982,5569981,5569980,5569979,5569978,5569977,5569976,5569975,5569974,5569973,5569972,5569971,5569970,5569969,5569968,5569967,5569966,5569965,5569964,5569963,5569962,5569961,5569960,5569959,5569958,5569957,5569956,5569955,5569954,5569953,5569952,5569951,5569950,5569949,5569948,5569947,5569946,5569945,5569944,5569943,5569942,5569941,5569940,5569939,5569938,5569937,5569936,5569935,5569934,5569933,5569932,5569931,5569930,5569929,5569928,5569927,5569926,5569925,5569924,5569923,5569922,5569921,5569920,5569919,5569918,5569917,5569916,5569915,5569914,5569913,5569912,5569911,5569910,5569909,5569908,5569907,5569906,5569905,5569904,5569903,5569902,5569901,5569900,5569899,5569898,5569897,5569896,5569895,5569894,5569893,5569892,5569891,5569890,5569889,5569888,5569887,5569886,5569885,5569884,5569883,5569882,5569881,5569880,5569879,5569878,5569877,5569876,5569875,5569874,5569873,5569872,5569871,5569870,5569869,5569868,5569867,5569866,5569865,5569864,5569863,5569862,5569861,5569860,5569859,5569858,5569857,5569856,5569855,5569854,5569853,5569852,5569851,5569850,5569849,5569848,5569847,5569846,5569845,5569844,5569843,5569842,5569841,5569840,5569839,5569838,5569837,5569836,5569835,5569834,5569833,5569832,5569831,5569830,5569829,5569828,5569827,5569826,5569825,5569824,5569823,5569822,5569821,5569820,5569819,5569818,5569817,5569816,5569815,5569814,5569813,5569812,5569811,5569810,5569809,5569808,5569807,5569806,5569805,5569804,5569803,5569802,5569801,5569800,5569799,5569798,5569797,5569796,5569795,5569794,5569793,5569792,5569791,5569790,5569789,5569788,5569787,5569786,5569785,5569784,5569783,5569782,5569781,5569780,5569779,5569778,5569777,5569776,5569775,5569774,5569773,5569772,5569771,5569770,5569769,5569768,5569767,5569766,5569765,5569764,5569763,5569762,5569761,5569760,5569759,5569758,5569757,5569756,5569755,5569754,5569753,5569752,5569751,5569750,5569749,5569748,5569747,5569746,5569745,5569744,5569743,5569742,5569741,5569740,5569739,5569738,5569737,5569736,5569735,5569734,5569733,5569732,5569731,5569730,5569729,5569728,5569727,5569726,5569725,5569724,5569723,5569722,5569721,5569720,5569719,5569718,5569717,5569716,5569715,5569714,5569713,5569712,5569711,5569710,5569709,5569708,5569707,5569706,5569705,5569704,5569703,5569702,5569701,5569700,5569699,5569698,5569697,5569696,5569695,5569694,5569693,5569692,5569691,5569690,5569689,5569688,5569687,5569686,5569685,5569684,5569683,5569682,5569681,5569680,5569679,5569678,5569677,5569676,5569675,5569674,5569673,5569672,5569671,5569670,5569669,5569668,5569667,5569666,5569665,5569664,5569663,5569662,5569661,5569660,5569659,5569658,5569657,5569656,5569655,5569654,5569653,5569652,5569651,5569650,5569649,5569648,5569647,5569646,5569645,5569644,5569643,5569642,5569641,5569640,5569639,5569638,5569637,5569636,5569635,5569634,5569633,5569632,5569631,5569630,5569629,5569628,5569627,5569626,5569625,5569624,5569623,5569622,5569621,5569620,5569619,5569618,5569617,5569616,5569615,5569614,5569613,5569612,5569611,5569610,5569609,5569608,5569607,5569606,5569605,5569604,5569603,5569602,5569601,5569600,5569599,5569598,5569597,5569596,5569595,5569594,5569593,5569592,5569591,5569590,5569589,5569588,5569587,5569586,5569585,5569584,5569583,5569582,5569581,5569580,5569579,5569578,5569577,5569576,5569575,5569574,5569573,5569572,5569571,5569570,5569569,5569568,5569567,5569566,5569565,5569564,5569563,5569562,5569561,5569560,5569559,5569558,5569557,5569556,5569555,5569554,5569553,5569552,5569551,5569550,5569549,5569548,5569547,5569546,5569545,5569544,5569543,5569542,5569541,5569540,5569539,5569538,5569537,5569536,5569535,5569534,5569533,5569532,5569531,5569530,5569529,5569528,5569527,5569526,5569525,5569524,5569523,5569522,5569521,5569520,5569519,5569518,5569517,5569516,5569515,5569514,5569513,5569512,5569511,5569510,5569509,5569508,5569507,5569506,5569505,5569504,5569503,5569502,5569501,5569500,5569499,5569498,5569497,5569496,5569495,5569494,5569493,5569492,5569491,5569490,5569489,5569488,5569487,5569486,5569485,5569484,5569483,5569482,5569481,5569480,5569479,5569478,5569477,5569476,5569475,5569474,5569473,5569472,5569471,5569470,5569469,5569468,5569467,5569466,5569465,5569464,5569463,5569462,5569461,5569460,5569459,5569458,5569457,5569456,5569455,5569454,5569453,5569452,5569451,5569450,5569449,5569448,5569447,5569446,5569445,5569444,5569443,5569442,5569441,5569440,5569439,5569438,5569437,5569436,5569435,5569434,5569433,5569432,5569431,5569430,5569429,5569428,5569427,5569426,5569425,5569424,5569423,5569422,5569421,5569420,5569419,5569418,5569417,5569416,5569415,5569414,5569413,5569412,5569411,5569410,5569409,5569408,5569407,5569406,5569405,5569404,5569403,5569402,5569401,5569400,5569399,5569398,5569397,5569396,5569395,5569394,5569393,5569392,5569391,5569390,5569389,5569388,5569387,5569386,5569385,5569384,5569383,5569382,5569381,5569380,5569379,5569378,5569377,5569376,5569375,5569374,5569373,5569372,5569371,5569370,5569369,5569368,5569367,5569366,5569365,5569364,5569363,5569362,5569361,5569360,5569359,5569358,5569357,5569356,5569355,5569354,5569353,5569352,5569351,5569350,5569349,5569348,5569347,5569346,5569345,5569344,5569343,5569342,5569341,5569340,5569339,5569338,5569337,5569336,5569335,5569334,5569333,5569332,5569331,5569330,5569329,5569328,5569327,5569326,5569325,5569324,5569323,5569322,5569321,5569320,5569319,5569318,5569317,5569316,5569315,5569314,5569313,5569312,5569311,5569310,5569309,5569308,5569307,5569306,5569305,5569304,5569303,5569302,5569301,5569300,5569299,5569298,5569297,5569296,5569295,5569294,5569293,5569292,5569291,5569290,5569289,5569288,5569287,5569286,5569285,5569284,5569283,5569282,5569281,5569280,5569279,5569278,5569277,5569276,5569275,5569274,5569273,5569272,5569271,5569270,5569269,5569268,5569267,5569266,5569265,5569264,5569263,5569262,5569261,5569260,5569259,5569258,5569257,5569256,5569255,5569254,5569253,5569252,5569251,5569250,5569249,5569248,5569247,5569246,5569245,5569244,5569243,5569242,5569241,5569240,5569239,5569238,5569237,5569236,5569235,5569234,5569233,5569232,5569231,5569230,5569229,5569228,5569227,5569226,5569225,5569224,5569223,5569222,5569221,5569220,5569219,5569218,5569217,5569216,5569215,5569214,5569213,5569212,5569211,5569210,5569209,5569208,5569207,5569206,5569205,5569204,5569203,5569202,5569201,5569200,5569199,5569198,5569197,5569196,5569195,5569194,5569193,5569192,5569191,5569190,5569189,5569188,5569187,5569186,5569185,5569184,5569183,5569182,5569181,5569180,5569179,5569178,5569177,5569176,5569175,5569174,5569173,5569172,5569171,5569170,5569169,5569168,5569167,5569166,5569165,5569164,5569163,5569162,5569161,5569160,5569159,5569158,5569157,5569156,5569155,5569154,5569153,5569152,5569151,5569150,5569149,5569148,5569147,5569146,5569145,5569144,5569143,5569142,5569141,5569140,5569139,5569138,5569137,5569136,5569135,5569134,5569133,5569132,5569131,5569130,5569129,5569128,5569127,5569126,5569125,5569124,5569123,5569122,5569121,5569120,5569119,5569118,5569117,5569116,5569115,5569114,5569113,5569112,5569111,5569110,5569109,5569108,5569107,5569106,5569105,5569104,5569103,5569102,5569101,5569100,5569099,5569098,5569097,5569096,5569095,5569094,5569093,5569092,5569091,5569090,5569089,5569088,5569087,5569086,5569085,5569084,5569083,5569082,5569081,5569080,5569079,5569078,5569077,5569076,5569075,5569074,5569073,5569072,5569071,5569070,5569069,5569068,5569067,5569066,5569065,5569064,5569063,5569062,5569061,5569060,5569059,5569058,5569057,5569056,5569055,5569054,5569053,5569052,5569051,5569050,5569049,5569048,5569047,5569046,5569045,5569044,5569043,5569042,5569041,5569040,5569039,5569038,5569037,5569036,5569035,5569034,5569033,5569032,5569031,5569030,5569029,5569028,5569027,5569026,5569025,5569024,5569023,5569022,5569021,5569020,5569019,5569018,5569017,5569016,5569015,5569014,5569013,5569012,5569011,5569010,5569009,5569008,5569007,5569006,5569005,5569004,5569003,5569002,5569001,5569000,5568999,5568998,5568997,5568996,5568995,5568994,5568993,5568992,5568991,5568990,5568989,5568988,5568987,5568986,5568985,5568984,5568983,5568982,5568981,5568980,5568979,5568978,5568977,5568976,5568975,5568974,5568973,5568972,5568971,5568970,3611235}'::text[]))
10. 0.000 0.000 ↓ 0.0

Hash (cost=47.28..47.28 rows=117 width=31) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Hash Join (cost=4.03..47.28 rows=117 width=31) (actual rows= loops=)

  • Hash Cond: (pa.maintainer_id = m.id)
12. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..42.36 rows=117 width=30) (actual rows= loops=)

  • Join Filter: (CASE WHEN (u.maintainer_id IS NOT NULL) THEN (u.maintainer_id = pa.maintainer_id) ELSE ((r.maintainer_id IS NULL) OR (pa.maintainer_id = r.maintainer_id)) END AND CASE WHEN ((r.restriction IS NOT NULL) AND ((r.restriction ->> 'park_restrictions'::text) <> ''::text) AND ((r.restriction ->> 'park_restrictions'::text) <> '[]'::text)) THEN (((r.restriction -> 'park_restrictions'::text))::jsonb @> ((pa.id)::text)::jsonb) ELSE true END)
13. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.56..8.62 rows=1 width=104) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.42..8.46 rows=1 width=8) (actual rows= loops=)

15. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=4) (actual rows= loops=)

16. 0.000 0.000 ↓ 0.0

Index Scan using users_pkey on users u (cost=0.42..8.44 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (id = (4))
17. 0.000 0.000 ↓ 0.0

Index Scan using roles_pkey on roles r (cost=0.14..0.16 rows=1 width=104) (actual rows= loops=)

  • Index Cond: (id = u.role_id)
18. 0.000 0.000 ↓ 0.0

Seq Scan on parks pa (cost=0.00..12.68 rows=468 width=30) (actual rows= loops=)

19. 0.000 0.000 ↓ 0.0

Hash (cost=2.65..2.65 rows=65 width=9) (actual rows= loops=)

20. 0.000 0.000 ↓ 0.0

Seq Scan on maintainers m (cost=0.00..2.65 rows=65 width=9) (actual rows= loops=)

21. 0.000 0.000 ↓ 0.0

Materialize (cost=7,535.97..7,535.98 rows=1 width=4) (actual rows= loops=)

22. 0.000 0.000 ↓ 0.0

Subquery Scan on ad (cost=7,535.97..7,535.98 rows=1 width=4) (actual rows= loops=)

23. 0.000 0.000 ↓ 0.0

Limit (cost=7,535.97..7,535.97 rows=1 width=48) (actual rows= loops=)

24. 0.000 0.000 ↓ 0.0

Sort (cost=7,535.97..7,704.11 rows=67,257 width=48) (actual rows= loops=)

  • Sort Key: at.creation_date DESC
25. 0.000 0.000 ↓ 0.0

HashAggregate (cost=6,527.11..7,199.68 rows=67,257 width=48) (actual rows= loops=)

  • Group Key: at.id
26. 0.000 0.000 ↓ 0.0

Hash Join (cost=3,720.32..6,358.97 rows=67,257 width=16) (actual rows= loops=)

  • Hash Cond: (at.action_id = a.id)
27. 0.000 0.000 ↓ 0.0

Seq Scan on action_terminals at (cost=0.00..1,789.57 rows=67,257 width=20) (actual rows= loops=)

28. 0.000 0.000 ↓ 0.0

Hash (cost=3,490.14..3,490.14 rows=18,414 width=4) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Seq Scan on actions a (cost=0.00..3,490.14 rows=18,414 width=4) (actual rows= loops=)

30.          

SubPlan (for Result)

31. 0.000 0.000 ↓ 0.0

Limit (cost=28.39..28.39 rows=1 width=44) (actual rows= loops=)

32. 0.000 0.000 ↓ 0.0

Sort (cost=28.39..28.39 rows=2 width=44) (actual rows= loops=)

  • Sort Key: at_1.creation_date DESC
33. 0.000 0.000 ↓ 0.0

GroupAggregate (cost=28.30..28.38 rows=2 width=44) (actual rows= loops=)

  • Group Key: at_1.id
34. 0.000 0.000 ↓ 0.0

Sort (cost=28.30..28.30 rows=2 width=99) (actual rows= loops=)

  • Sort Key: at_1.id
35. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.58..28.29 rows=2 width=99) (actual rows= loops=)

36. 0.000 0.000 ↓ 0.0

Index Scan using action_terminals_terminal_id_index on action_terminals at_1 (cost=0.29..11.68 rows=2 width=59) (actual rows= loops=)

  • Index Cond: (terminal_id = t.id)
37. 0.000 0.000 ↓ 0.0

Index Scan using actions_pkey on actions a_1 (cost=0.29..8.30 rows=1 width=44) (actual rows= loops=)

  • Index Cond: (id = at_1.action_id)
38. 0.000 0.000 ↓ 0.0

Index Scan using parks_pkey on parks (cost=0.27..8.29 rows=1 width=5) (actual rows= loops=)

  • Index Cond: (id = t.park_emigrate)