summaryrefslogtreecommitdiff
path: root/sql/sql_select.cc
diff options
context:
space:
mode:
authorRucha Deodhar <rucha.deodhar@mariadb.com>2022-01-22 16:51:21 +0530
committerRucha Deodhar <rucha.deodhar@mariadb.com>2022-01-22 22:23:13 +0530
commit5e04903f592bb425d52f9fa18388e1e64b67497f (patch)
tree8f4a08658455c4759eacb21c9de3c53238ab6c8a /sql/sql_select.cc
parent5e6fd4e80435ae6d5994abbff6032c7957713410 (diff)
downloadmariadb-git-bb-10.7-MDEV-26843.tar.gz
MDEV-26843: Inconsistent behavior of ROW_NUMBER upon resignalling frombb-10.7-MDEV-26843
function Analysis: m_current_row_for_warning is reset to 0 earlier so new value '0' of the counter gets recorded for error condition. Fix: reset m_current_row_for_warning after other error conditions.
Diffstat (limited to 'sql/sql_select.cc')
-rw-r--r--sql/sql_select.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index ae5cd82da4c..5dd5e87d33e 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -1395,7 +1395,7 @@ JOIN::prepare(TABLE_LIST *tables_init, COND *conds_init, uint og_num,
}
if (setup_fields(thd, ref_ptrs, fields_list, MARK_COLUMNS_READ,
- &all_fields, &select_lex->pre_fix, 1))
+ &all_fields, &select_lex->pre_fix, 1, 0))
DBUG_RETURN(-1);
thd->lex->current_select->context_analysis_place= save_place;
rand_table_in_field_list= select_lex->select_list_tables & RAND_TABLE_BIT;