1
0
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:
unknown
2005-01-18 23:13:29 +02:00
parent e46d235a08
commit 59ef5bede9
3 changed files with 27 additions and 4 deletions

View File

@@ -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)