Open coryfoo opened 7 years ago
When a query plan results in using a parallel sequential scan, there is an array of objects with statistics for each worker.
Here is a real example from a plan:
"Plans": [ { ..., "Workers":[ { "Worker Number": 0, "Actual Startup Time": 130407.893, "Actual Total Time": 490126.071, "Actual Rows": 86, "Actual Loops": 1, "Shared Hit Blocks": 2945119, "Shared Read Blocks": 2804690, "Shared Dirtied Blocks": 0, "Shared Written Blocks": 0, "Local Hit Blocks": 0, "Local Read Blocks": 0, "Local Dirtied Blocks": 0, "Local Written Blocks": 0, "Temp Read Blocks": 5602, "Temp Written Blocks": 5596 }, { "Worker Number": 1, "Actual Startup Time": 138177.085, "Actual Total Time": 529953.618, "Actual Rows": 96, "Actual Loops": 1, "Shared Hit Blocks": 3406372, "Shared Read Blocks": 3259171, "Shared Dirtied Blocks": 0, "Shared Written Blocks": 0, "Local Hit Blocks": 0, "Local Read Blocks": 0, "Local Dirtied Blocks": 0, "Local Written Blocks": 0, "Temp Read Blocks": 5602, "Temp Written Blocks": 5596 } ] } ]
Also, with parallel plans, the worker nodes are summed up to create a much higher duration than is actual.
When a query plan results in using a parallel sequential scan, there is an array of objects with statistics for each worker.
Here is a real example from a plan: