The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
{
    'type'                   => 'Limit',
    'estimated_startup_cost' => '186.82',
    'estimated_total_cost'   => '186.82',
    'estimated_rows'         => '1',
    'estimated_row_width'    => '359',
    'actual_time_first'      => '1352.355',
    'actual_time_last'       => '1352.405',
    'actual_rows'            => '50',
    'actual_loops'           => '1',
    'is_analyzed'            => 1,
    'sub_nodes'              => [
        {
            'type'                   => 'Sort',
            'estimated_startup_cost' => '186.82',
            'estimated_total_cost'   => '186.82',
            'estimated_rows'         => '1',
            'estimated_row_width'    => '359',
            'actual_time_first'      => '1352.354',
            'actual_time_last'       => '1352.373',
            'actual_rows'            => '50',
            'actual_loops'           => '1',
            'is_analyzed'            => 1,
            'extra_info'             => [ 'Sort Key: s.last_updated_date', 'Sort Method:  top-N heapsort  Memory: 50kB', ],
            'sub_nodes'              => [
                {
                    'type'                   => 'Nested Loop Left Join',
                    'estimated_startup_cost' => '2.16',
                    'estimated_total_cost'   => '186.81',
                    'estimated_rows'         => '1',
                    'estimated_row_width'    => '359',
                    'actual_time_first'      => '0.733',
                    'actual_time_last'       => '1271.399',
                    'actual_rows'            => '13988',
                    'actual_loops'           => '1',
                    'is_analyzed'            => 1,
                    'sub_nodes'              => [
                        {
                            'type'                   => 'Nested Loop Left Join',
                            'estimated_startup_cost' => '2.16',
                            'estimated_total_cost'   => '186.49',
                            'estimated_rows'         => '1',
                            'estimated_row_width'    => '351',
                            'actual_time_first'      => '0.706',
                            'actual_time_last'       => '1116.63',
                            'actual_rows'            => '13988',
                            'actual_loops'           => '1',
                            'is_analyzed'            => 1,
                            'extra_info'             => [ 'Filter: ((mu.mls_id IS NULL) OR (mu.mls_update_id = (subplan)))' ],
                            'sub_nodes'              => [
                                {
                                    'type'                   => 'Nested Loop',
                                    'estimated_startup_cost' => '2.16',
                                    'estimated_total_cost'   => '19.03',
                                    'estimated_rows'         => '1',
                                    'estimated_row_width'    => '321',
                                    'actual_time_first'      => '0.676',
                                    'actual_time_last'       => '204.019',
                                    'actual_rows'            => '13988',
                                    'actual_loops'           => '1',
                                    'is_analyzed'            => 1,
                                    'extra_info'             => [ 'Join Filter: _st_contains(poly_inter_1.the_geom, s.centroid)' ],
                                    'sub_nodes'              => [
                                        {
                                            'type'                   => 'Subquery Scan poly_inter_1',
                                            'estimated_startup_cost' => '2.16',
                                            'estimated_total_cost'   => '2.44',
                                            'estimated_rows'         => '1',
                                            'estimated_row_width'    => '32',
                                            'actual_time_first'      => '0.52',
                                            'actual_time_last'       => '0.531',
                                            'actual_rows'            => '1',
                                            'actual_loops'           => '1',
                                            'is_analyzed'            => 1,
                                            'extra_info'             => [ q{Filter: (st_geometrytype(poly_inter_1.the_geom) ~~* '%polygon%'::text)} ],
                                            'sub_nodes'              => [
                                                {
                                                    'type'                   => 'Result',
                                                    'estimated_startup_cost' => '2.16',
                                                    'estimated_total_cost'   => '2.18',
                                                    'estimated_rows'         => '1',
                                                    'estimated_row_width'    => '0',
                                                    'actual_time_first'      => '0.433',
                                                    'actual_time_last'       => '0.441',
                                                    'actual_rows'            => '1',
                                                    'actual_loops'           => '1',
                                                    'is_analyzed'            => 1,
                                                    'initplans'              => [
                                                        {
                                                            'type'                   => 'Seq Scan',
                                                            'estimated_startup_cost' => '0',
                                                            'estimated_total_cost'   => '2.15',
                                                            'estimated_rows'         => '1',
                                                            'estimated_row_width'    => '32',
                                                            'actual_time_first'      => '0.015',
                                                            'actual_time_last'       => '0.02',
                                                            'actual_rows'            => '1',
                                                            'actual_loops'           => '1',
                                                            'is_analyzed'            => 1,
                                                            'extra_info'             => [ q{Filter: ((name)::text = 'seattle'::text)} ],
                                                            'scan_on'                => { 'table_name' => 'markets', },
                                                        },
                                                        {
                                                            'type'                   => 'Result',
                                                            'estimated_startup_cost' => '0',
                                                            'estimated_total_cost'   => '0.01',
                                                            'estimated_rows'         => '1',
                                                            'estimated_row_width'    => '0',
                                                            'actual_time_first'      => '0.048',
                                                            'actual_time_last'       => '0.05',
                                                            'actual_rows'            => '1',
                                                            'actual_loops'           => '1',
                                                            'is_analyzed'            => 1,
                                                        }
                                                    ],
                                                }
                                            ],
                                        },
                                        {
                                            'type'                   => 'Index Scan',
                                            'estimated_startup_cost' => '0',
                                            'estimated_total_cost'   => '16.58',
                                            'estimated_rows'         => '1',
                                            'estimated_row_width'    => '421',
                                            'actual_time_first'      => '0.131',
                                            'actual_time_last'       => '139.571',
                                            'actual_rows'            => '13988',
                                            'actual_loops'           => '1',
                                            'is_analyzed'            => 1,
                                            'extra_info'             => [
                                                'Index Cond: (poly_inter_1.the_geom && s.centroid)',
q{Filter: ((NOT s.is_townhome) AND (s.property_type_id = ANY ('{3,6}'::bigint[])) AND (s.access_level <= 3) AND (s.listing_type_id = ANY ('{1,2,3}'::integer[])) AND (0 <> (s.search_status_id & 1)) AND (s.last_updated_date >= (('now'::text)::date - '7 days'::interval)))},
                                            ],
                                            'scan_on' => {
                                                'index_name'  => 'listing_search_keys_centroid',
                                                'table_name'  => 'listing_search_keys',
                                                'table_alias' => 's',
                                            },
                                        },
                                    ],
                                },
                                {
                                    'type'                   => 'Index Scan',
                                    'estimated_startup_cost' => '0',
                                    'estimated_total_cost'   => '4.19',
                                    'estimated_rows'         => '7',
                                    'estimated_row_width'    => '55',
                                    'actual_time_first'      => '0.01',
                                    'actual_time_last'       => '0.012',
                                    'actual_rows'            => '2',
                                    'actual_loops'           => '13988',
                                    'is_analyzed'            => 1,
                                    'extra_info'             => [
                                        'Index Cond: (mu.listing_id = s.listing_id)',
q{Filter: (((mu.mls_column_updated)::text <> 'search_status_id'::text) OR (((mu.mls_column_old_value)::text <> '32'::text) AND ((mu.mls_column_new_value)::text <> '32'::text)))},
                                    ],
                                    'scan_on' => {
                                        'index_name'  => 'mls_updates_listing_id_and_field',
                                        'table_name'  => 'mls_updates',
                                        'table_alias' => 'mu',
                                    },
                                },
                            ],
                            'subplans' => [
                                {
                                    'type'                   => 'Limit',
                                    'estimated_startup_cost' => '23.31',
                                    'estimated_total_cost'   => '23.31',
                                    'estimated_rows'         => '1',
                                    'estimated_row_width'    => '16',
                                    'actual_time_first'      => '0.03',
                                    'actual_time_last'       => '0.031',
                                    'actual_rows'            => '1',
                                    'actual_loops'           => '22035',
                                    'is_analyzed'            => 1,
                                    'sub_nodes'              => [
                                        {
                                            'type'                   => 'Sort',
                                            'estimated_startup_cost' => '23.31',
                                            'estimated_total_cost'   => '23.32',
                                            'estimated_rows'         => '7',
                                            'estimated_row_width'    => '16',
                                            'actual_time_first'      => '0.029',
                                            'actual_time_last'       => '0.029',
                                            'actual_rows'            => '1',
                                            'actual_loops'           => '22035',
                                            'is_analyzed'            => 1,
                                            'extra_info'             => [ 'Sort Key: mu2.update_date', 'Sort Method:  quicksort  Memory: 25kB', ],
                                            'sub_nodes'              => [
                                                {
                                                    'type'                   => 'Index Scan',
                                                    'estimated_startup_cost' => '0',
                                                    'estimated_total_cost'   => '23.27',
                                                    'estimated_rows'         => '7',
                                                    'estimated_row_width'    => '16',
                                                    'actual_time_first'      => '0.005',
                                                    'actual_time_last'       => '0.019',
                                                    'actual_rows'            => '12',
                                                    'actual_loops'           => '22035',
                                                    'is_analyzed'            => 1,
                                                    'extra_info'             => [
                                                        'Index Cond: (listing_id = $0)',
q{Filter: (((mls_column_updated)::text <> 'search_status_id'::text) OR (((mls_column_old_value)::text <> '32'::text) AND ((mls_column_new_value)::text <> '32'::text)))},
                                                    ],
                                                    'scan_on' => {
                                                        'index_name'  => 'mls_updates_listing_id_and_field',
                                                        'table_name'  => 'mls_updates',
                                                        'table_alias' => 'mu2',
                                                    },
                                                },
                                            ],
                                        }
                                    ],
                                },
                            ],
                        },
                        {
                            'type'                   => 'Index Scan',
                            'estimated_startup_cost' => '0',
                            'estimated_total_cost'   => '0.27',
                            'estimated_rows'         => '1',
                            'estimated_row_width'    => '16',
                            'actual_time_first'      => '0.002',
                            'actual_time_last'       => '0.003',
                            'actual_rows'            => '1',
                            'actual_loops'           => '13988',
                            'is_analyzed'            => 1,
                            'extra_info'             => [ 'Index Cond: (s.primary_market_id = m.market_id)' ],
                            'scan_on'                => {
                                'index_name'  => 'markets_pkey',
                                'table_name'  => 'markets',
                                'table_alias' => 'm',
                            },
                        },
                    ],
                },
            ],
        }
    ]
}