From 877bd85d6a548edcc1ae7600ba0a3cc117e484ff Mon Sep 17 00:00:00 2001 From: drrtuy Date: Wed, 6 Aug 2025 12:20:57 +0000 Subject: [PATCH] chore(QA): removed commented code. --- dbcon/mysql/ha_mcs_execplan.cpp | 48 ++------------------------------- 1 file changed, 2 insertions(+), 46 deletions(-) diff --git a/dbcon/mysql/ha_mcs_execplan.cpp b/dbcon/mysql/ha_mcs_execplan.cpp index f5fa7db42..57a0abc62 100644 --- a/dbcon/mysql/ha_mcs_execplan.cpp +++ b/dbcon/mysql/ha_mcs_execplan.cpp @@ -5204,10 +5204,8 @@ void setExecutionParams(gp_walk_info& gwi, SCSEP& csep) csep->umMemLimit(get_um_mem_limit(gwi.thd) * 1024ULL * 1024); } -// Loop over available indexes to find and extract corresponding EI column statistics -// for the first column of the index if any. -// Statistics is stored in GWI context. -// Mock for ES 10.6 +// Loop over indexes available for a table to find and extract corresponding Engine Independent column +// statistics for the first column of the index if any. Statistics are stored in a GWI context. Mock for ES 10.6 // TODO clean up extra logging when the feature is ready #if MYSQL_VERSION_ID >= 110401 void extractColumnStatistics(TABLE_LIST* table_ptr, gp_walk_info& gwi) @@ -6440,48 +6438,6 @@ int processLimitAndOffset(SELECT_LEX& select_lex, gp_walk_info& gwi, SCSEP& csep return 0; } -// Loop over available indexes to find and extract corresponding EI column statistics -// for the first column of the index if any. -// Statistics is stored in GWI context. -// Mock for ES 10.6 -// #if MYSQL_VERSION_ID >= 120401 -// void extractColumnStatistics(Item_field* ifp, gp_walk_info& gwi) -// { -// for (uint j = 0; j < ifp->field->table->s->keys; j++) -// { -// for (uint i = 0; i < ifp->field->table->s->key_info[j].usable_key_parts; i++) -// { -// if (ifp->field->table->s->key_info[j].key_part[i].fieldnr == ifp->field->field_index + 1) -// { -// if (i == 0 && ifp->field->read_stats) -// { -// assert(ifp->field->table->s); -// auto* histogram = dynamic_cast(ifp->field->read_stats->histogram); -// if (histogram) -// { -// SchemaAndTableName tableName = {ifp->field->table->s->db.str, -// ifp->field->table->s->table_name.str}; -// auto tableStatisticsMapIt = gwi.tableStatisticsMap.find(tableName); -// if (tableStatisticsMapIt == gwi.tableStatisticsMap.end()) -// { -// gwi.tableStatisticsMap.insert({tableName, {{ifp->field->field_name.str, *histogram}}}); -// } -// else -// { -// tableStatisticsMapIt->second.insert({ifp->field->field_name.str, *histogram}); -// } -// } -// } -// } -// } -// } -// } -// #else -// void extractColumnStatistics(Item_field* /*ifp*/, gp_walk_info& /*gwi*/) -// { -// } -// #endif - /*@brief Process SELECT part of a query or sub-query */ /*********************************************************** * DESCRIPTION: