|
"QUERY PLAN"
|
|
"[
|
|
{
|
|
""Plan"": {
|
|
""Node Type"": ""Sort"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 3444.66,
|
|
""Total Cost"": 3448.82,
|
|
""Plan Rows"": 1665,
|
|
""Plan Width"": 276,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 1,
|
|
""Sort Key"": [""issues.id DESC""],
|
|
""Sort Method"": ""quicksort"",
|
|
""Sort Space Used"": 25,
|
|
""Sort Space Type"": ""Memory"",
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Hash Join"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Inner"",
|
|
""Startup Cost"": 122.45,
|
|
""Total Cost"": 3355.57,
|
|
""Plan Rows"": 1665,
|
|
""Plan Width"": 276,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 1,
|
|
""Inner Unique"": true,
|
|
""Hash Cond"": ""(issues.status_id = issue_statuses.id)"",
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Hash Join"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Semi"",
|
|
""Startup Cost"": 121.31,
|
|
""Total Cost"": 3346.97,
|
|
""Plan Rows"": 1665,
|
|
""Plan Width"": 260,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 1,
|
|
""Inner Unique"": false,
|
|
""Hash Cond"": ""(projects.id = em.project_id)"",
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Hash Join"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Inner"",
|
|
""Startup Cost"": 22.05,
|
|
""Total Cost"": 3206.07,
|
|
""Plan Rows"": 1672,
|
|
""Plan Width"": 260,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 1,
|
|
""Inner Unique"": true,
|
|
""Hash Cond"": ""(issues.project_id = projects.id)"",
|
|
""Join Filter"": ""(SubPlan 4)"",
|
|
""Rows Removed by Join Filter"": 5012,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Hash Join"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Inner"",
|
|
""Startup Cost"": 1.11,
|
|
""Total Cost"": 149.72,
|
|
""Plan Rows"": 3343,
|
|
""Plan Width"": 152,
|
|
""Actual Rows"": 5012,
|
|
""Actual Loops"": 1,
|
|
""Inner Unique"": true,
|
|
""Hash Cond"": ""(issues.status_id = issue_statuses_1.id)"",
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""issues"",
|
|
""Alias"": ""issues"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 126.15,
|
|
""Plan Rows"": 5015,
|
|
""Plan Width"": 148,
|
|
""Actual Rows"": 5015,
|
|
""Actual Loops"": 1
|
|
},
|
|
{
|
|
""Node Type"": ""Hash"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 1.06,
|
|
""Total Cost"": 1.06,
|
|
""Plan Rows"": 4,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 4,
|
|
""Actual Loops"": 1,
|
|
""Hash Buckets"": 1024,
|
|
""Original Hash Buckets"": 1024,
|
|
""Hash Batches"": 1,
|
|
""Original Hash Batches"": 1,
|
|
""Peak Memory Usage"": 9,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""issue_statuses"",
|
|
""Alias"": ""issue_statuses_1"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 1.06,
|
|
""Plan Rows"": 4,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 4,
|
|
""Actual Loops"": 1,
|
|
""Filter"": ""(NOT is_closed)"",
|
|
""Rows Removed by Filter"": 2
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Hash"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 14.61,
|
|
""Total Cost"": 14.61,
|
|
""Plan Rows"": 507,
|
|
""Plan Width"": 108,
|
|
""Actual Rows"": 507,
|
|
""Actual Loops"": 1,
|
|
""Hash Buckets"": 1024,
|
|
""Original Hash Buckets"": 1024,
|
|
""Hash Batches"": 1,
|
|
""Original Hash Batches"": 1,
|
|
""Peak Memory Usage"": 63,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""projects"",
|
|
""Alias"": ""projects"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 14.61,
|
|
""Plan Rows"": 507,
|
|
""Plan Width"": 108,
|
|
""Actual Rows"": 507,
|
|
""Actual Loops"": 1,
|
|
""Filter"": ""((status <> 9) AND (status <> 10))"",
|
|
""Rows Removed by Filter"": 0
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Result"",
|
|
""Parent Relationship"": ""SubPlan"",
|
|
""Subplan Name"": ""SubPlan 4"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 77.45,
|
|
""Total Cost"": 1940.27,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 5012,
|
|
""One-Time Filter"": ""((projects.status <> 9) AND (projects.status <> 10) AND $3)"",
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""InitPlan"",
|
|
""Subplan Name"": ""InitPlan 1 (returns $0)"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""custom_fields"",
|
|
""Alias"": ""ifa"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 1.14,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 0,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Filter"": ""(is_for_all AND (id = 13))"",
|
|
""Rows Removed by Filter"": 0
|
|
},
|
|
{
|
|
""Node Type"": ""Index Scan"",
|
|
""Parent Relationship"": ""InitPlan"",
|
|
""Subplan Name"": ""InitPlan 3 (returns $3)"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Scan Direction"": ""Forward"",
|
|
""Index Name"": ""enabled_modules_project_id"",
|
|
""Relation Name"": ""enabled_modules"",
|
|
""Alias"": ""em_1"",
|
|
""Startup Cost"": 0.28,
|
|
""Total Cost"": 8.48,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 0,
|
|
""Actual Rows"": 1,
|
|
""Actual Loops"": 5012,
|
|
""Index Cond"": ""(project_id = projects.id)"",
|
|
""Rows Removed by Index Recheck"": 0,
|
|
""Filter"": ""((name)::text = 'issue_tracking'::text)"",
|
|
""Rows Removed by Filter"": 0
|
|
},
|
|
{
|
|
""Node Type"": ""Nested Loop"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Inner"",
|
|
""Startup Cost"": 77.45,
|
|
""Total Cost"": 1940.27,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 4988,
|
|
""Inner Unique"": true,
|
|
""Join Filter"": ""(issues_1.tracker_id = custom_fields_trackers.tracker_id)"",
|
|
""Rows Removed by Join Filter"": 0,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Nested Loop"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Join Type"": ""Inner"",
|
|
""Startup Cost"": 67.83,
|
|
""Total Cost"": 1927.57,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 8,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 4988,
|
|
""Inner Unique"": true,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Bitmap Heap Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""custom_values"",
|
|
""Alias"": ""custom_values"",
|
|
""Startup Cost"": 52.61,
|
|
""Total Cost"": 1904.32,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 4988,
|
|
""Recheck Cond"": ""(custom_field_id = 13)"",
|
|
""Rows Removed by Index Recheck"": 0,
|
|
""Filter"": ""((value ~~* '%text%'::text) AND ((customized_type)::text = 'Issue'::text))"",
|
|
""Rows Removed by Filter"": 5001,
|
|
""Exact Heap Blocks"": 8798832,
|
|
""Lossy Heap Blocks"": 0,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Bitmap Index Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Index Name"": ""index_custom_values_on_custom_field_id"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 52.60,
|
|
""Plan Rows"": 4841,
|
|
""Plan Width"": 0,
|
|
""Actual Rows"": 5001,
|
|
""Actual Loops"": 4988,
|
|
""Index Cond"": ""(custom_field_id = 13)""
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Index Scan"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Scan Direction"": ""Forward"",
|
|
""Index Name"": ""issues_pkey"",
|
|
""Relation Name"": ""issues"",
|
|
""Alias"": ""issues_1"",
|
|
""Startup Cost"": 15.22,
|
|
""Total Cost"": 23.24,
|
|
""Plan Rows"": 1,
|
|
""Plan Width"": 8,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Index Cond"": ""(id = custom_values.customized_id)"",
|
|
""Rows Removed by Index Recheck"": 0,
|
|
""Filter"": ""($0 OR (hashed SubPlan 2))"",
|
|
""Rows Removed by Filter"": 0,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Bitmap Heap Scan"",
|
|
""Parent Relationship"": ""SubPlan"",
|
|
""Subplan Name"": ""SubPlan 2"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""custom_fields_projects"",
|
|
""Alias"": ""custom_fields_projects"",
|
|
""Startup Cost"": 4.24,
|
|
""Total Cost"": 14.91,
|
|
""Plan Rows"": 11,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Recheck Cond"": ""(custom_field_id = 13)"",
|
|
""Rows Removed by Index Recheck"": 0,
|
|
""Exact Heap Blocks"": 0,
|
|
""Lossy Heap Blocks"": 0,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Bitmap Index Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Index Name"": ""index_custom_fields_projects_on_custom_field_id_and_project_id"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 4.24,
|
|
""Plan Rows"": 11,
|
|
""Plan Width"": 0,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Index Cond"": ""(custom_field_id = 13)""
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""custom_fields_trackers"",
|
|
""Alias"": ""custom_fields_trackers"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 3.04,
|
|
""Plan Rows"": 3,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Filter"": ""(custom_field_id = 13)"",
|
|
""Rows Removed by Filter"": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Hash"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 92.95,
|
|
""Total Cost"": 92.95,
|
|
""Plan Rows"": 505,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""enabled_modules"",
|
|
""Alias"": ""em"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 92.95,
|
|
""Plan Rows"": 505,
|
|
""Plan Width"": 4,
|
|
""Actual Rows"": 0,
|
|
""Actual Loops"": 0,
|
|
""Filter"": ""((name)::text = 'issue_tracking'::text)"",
|
|
""Rows Removed by Filter"": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
""Node Type"": ""Hash"",
|
|
""Parent Relationship"": ""Inner"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Startup Cost"": 1.06,
|
|
""Total Cost"": 1.06,
|
|
""Plan Rows"": 6,
|
|
""Plan Width"": 20,
|
|
""Actual Rows"": 6,
|
|
""Actual Loops"": 1,
|
|
""Hash Buckets"": 1024,
|
|
""Original Hash Buckets"": 1024,
|
|
""Hash Batches"": 1,
|
|
""Original Hash Batches"": 1,
|
|
""Peak Memory Usage"": 9,
|
|
""Plans"": [
|
|
{
|
|
""Node Type"": ""Seq Scan"",
|
|
""Parent Relationship"": ""Outer"",
|
|
""Parallel Aware"": false,
|
|
""Async Capable"": false,
|
|
""Relation Name"": ""issue_statuses"",
|
|
""Alias"": ""issue_statuses"",
|
|
""Startup Cost"": 0.00,
|
|
""Total Cost"": 1.06,
|
|
""Plan Rows"": 6,
|
|
""Plan Width"": 20,
|
|
""Actual Rows"": 6,
|
|
""Actual Loops"": 1
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
""Planning Time"": 16.942,
|
|
""Triggers"": [
|
|
],
|
|
""Execution Time"": 5417.890
|
|
}
|
|
]"
|