semillero-INVIMA/benchmarks/results/explain_after/query_04.json

263 lines
9.4 KiB
JSON

{
"phase": "after",
"generatedAt": "2026-07-12T23:09:21.185Z",
"queryId": "query_04",
"queryName": "Conteo de dispositivos vigentes",
"sqlFile": "queries/query_04.sql",
"explain": {
"Plan": {
"Node Type": "Aggregate",
"Strategy": "Plain",
"Partial Mode": "Finalize",
"Parallel Aware": false,
"Async Capable": false,
"Startup Cost": 130152.46,
"Total Cost": 130152.47,
"Plan Rows": 1,
"Plan Width": 8,
"Actual Startup Time": 247.009,
"Actual Total Time": 252.955,
"Actual Rows": 1,
"Actual Loops": 1,
"Disabled": false,
"Output": [
"count(*)"
],
"Shared Hit Blocks": 305,
"Shared Read Blocks": 50010,
"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": 0,
"Temp Written Blocks": 0,
"Plans": [
{
"Node Type": "Gather",
"Parent Relationship": "Outer",
"Parallel Aware": false,
"Async Capable": false,
"Startup Cost": 130152.24,
"Total Cost": 130152.45,
"Plan Rows": 2,
"Plan Width": 8,
"Actual Startup Time": 247.003,
"Actual Total Time": 252.951,
"Actual Rows": 3,
"Actual Loops": 1,
"Disabled": false,
"Output": [
"(PARTIAL count(*))"
],
"Workers Planned": 2,
"Workers Launched": 2,
"Single Copy": false,
"Shared Hit Blocks": 305,
"Shared Read Blocks": 50010,
"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": 0,
"Temp Written Blocks": 0,
"Plans": [
{
"Node Type": "Aggregate",
"Strategy": "Plain",
"Partial Mode": "Partial",
"Parent Relationship": "Outer",
"Parallel Aware": false,
"Async Capable": false,
"Startup Cost": 129152.24,
"Total Cost": 129152.25,
"Plan Rows": 1,
"Plan Width": 8,
"Actual Startup Time": 224.765,
"Actual Total Time": 224.765,
"Actual Rows": 1,
"Actual Loops": 3,
"Disabled": false,
"Output": [
"PARTIAL count(*)"
],
"Shared Hit Blocks": 305,
"Shared Read Blocks": 50010,
"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": 0,
"Temp Written Blocks": 0,
"Workers": [
{
"Worker Number": 0,
"Actual Startup Time": 215.434,
"Actual Total Time": 215.434,
"Actual Rows": 1,
"Actual Loops": 1,
"Shared Hit Blocks": 96,
"Shared Read Blocks": 15502,
"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": 0,
"Temp Written Blocks": 0
},
{
"Worker Number": 1,
"Actual Startup Time": 212.201,
"Actual Total Time": 212.202,
"Actual Rows": 1,
"Actual Loops": 1,
"Shared Hit Blocks": 84,
"Shared Read Blocks": 15416,
"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": 0,
"Temp Written Blocks": 0
}
],
"Plans": [
{
"Node Type": "Index Scan",
"Parent Relationship": "Outer",
"Parallel Aware": true,
"Async Capable": false,
"Scan Direction": "Forward",
"Index Name": "idx_invima_api_catalog_dataset",
"Relation Name": "invima_api_catalog",
"Schema": "public",
"Alias": "invima_api_catalog",
"Startup Cost": 0.43,
"Total Cost": 129152.2,
"Plan Rows": 17,
"Plan Width": 0,
"Actual Startup Time": 0.384,
"Actual Total Time": 222.921,
"Actual Rows": 41705.67,
"Actual Loops": 3,
"Disabled": false,
"Output": [
"source_dataset_key",
"source_dataset_id",
"source_uid",
"source_dataset_name",
"categoria_linea",
"expediente",
"registro_sanitario",
"producto",
"titular",
"estado_registro",
"fecha_expedicion",
"fecha_vencimiento",
"modalidad",
"grupo",
"marca",
"principio_activo",
"forma_farmaceutica",
"presentacion_comercial",
"atc",
"rol_nombre",
"rol_tipo",
"ciudad_titular",
"pais_titular",
"fabricante",
"importador",
"vigencia",
"extra",
"fetched_at",
"updated_at",
"categoria_canonica",
"categoria_slug",
"search_text"
],
"Index Cond": "(invima_api_catalog.source_dataset_key = 'dispositivos'::text)",
"Rows Removed by Index Recheck": 0,
"Filter": "((COALESCE(invima_api_catalog.estado_registro, ''::text) !~~* '%no vigente%'::text) AND (COALESCE(invima_api_catalog.vigencia, ''::text) !~~* '%no vigente%'::text) AND ((COALESCE(invima_api_catalog.estado_registro, ''::text) ~~* '%vigente%'::text) OR (COALESCE(invima_api_catalog.vigencia, ''::text) ~~* '%vigente%'::text)))",
"Rows Removed by Filter": 21496,
"Index Searches": 1,
"Shared Hit Blocks": 305,
"Shared Read Blocks": 50010,
"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": 0,
"Temp Written Blocks": 0,
"Workers": [
{
"Worker Number": 0,
"Actual Startup Time": 0.633,
"Actual Total Time": 213.609,
"Actual Rows": 37514,
"Actual Loops": 1,
"Shared Hit Blocks": 96,
"Shared Read Blocks": 15502,
"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": 0,
"Temp Written Blocks": 0
},
{
"Worker Number": 1,
"Actual Startup Time": 0.403,
"Actual Total Time": 210.596,
"Actual Rows": 37960,
"Actual Loops": 1,
"Shared Hit Blocks": 84,
"Shared Read Blocks": 15416,
"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": 0,
"Temp Written Blocks": 0
}
]
}
]
}
]
}
]
},
"Settings": {},
"Planning": {
"Shared Hit Blocks": 0,
"Shared Read Blocks": 0,
"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": 0,
"Temp Written Blocks": 0
},
"Planning Time": 0.175,
"Triggers": [],
"Execution Time": 253.056
}
}