mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
fixing wrong value for "examined rows" when UNION's are used.
mysql-test/r/union.result: result for a test case for the wrong examined rows with UNION's mysql-test/t/union.test: test case for the wrong examined rows with UNION's sql/sql_union.cc: a patch for the wrong examined rows with UNION's
This commit is contained in:
@@ -466,11 +466,14 @@ int st_select_lex_unit::exec()
|
||||
}
|
||||
res= sl->join->error;
|
||||
offset_limit_cnt= sl->offset_limit;
|
||||
if (!res && union_result->flush())
|
||||
if (!res)
|
||||
{
|
||||
examined_rows+= thd->examined_row_count;
|
||||
thd->lex->current_select= lex_select_save;
|
||||
DBUG_RETURN(1);
|
||||
examined_rows+= thd->examined_row_count;
|
||||
if (union_result->flush())
|
||||
{
|
||||
thd->lex->current_select= lex_select_save;
|
||||
DBUG_RETURN(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (res)
|
||||
|
Reference in New Issue
Block a user