diff options
author | monty@mysql.com <> | 2004-10-06 19:14:33 +0300 |
---|---|---|
committer | monty@mysql.com <> | 2004-10-06 19:14:33 +0300 |
commit | 62f3cd6a31d3c1ffe7ad17d9de862a3c0859f56a (patch) | |
tree | 4e2cfa6a6a8032773454e22aa802b2798b2935b8 /sql/sql_union.cc | |
parent | 96458f8f64641d5b974a17733af8c709b513bfe0 (diff) | |
parent | 0944bed7fcb59fb38230a750bd820a22b3b6b476 (diff) | |
download | mariadb-git-62f3cd6a31d3c1ffe7ad17d9de862a3c0859f56a.tar.gz |
Merge with 4.0 for 4.1 release
Noteworthy:
- New HANDLER code
- New multi-update-grant-check code
- Table lock code in ha_innodb.cc was not applied
Diffstat (limited to 'sql/sql_union.cc')
-rw-r--r-- | sql/sql_union.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sql_union.cc b/sql/sql_union.cc index 1e8c6576dec..b46cfc05538 100644 --- a/sql/sql_union.cc +++ b/sql/sql_union.cc @@ -346,6 +346,7 @@ int st_select_lex_unit::exec() SELECT_LEX *lex_select_save= thd->lex->current_select; SELECT_LEX *select_cursor=first_select_in_union(); ulonglong add_rows=0; + ha_rows examined_rows= 0; DBUG_ENTER("st_select_lex_unit::exec"); if (executed && !uncacheable && !describe) @@ -426,6 +427,7 @@ int st_select_lex_unit::exec() offset_limit_cnt= sl->offset_limit; if (!res && union_result->flush()) { + examined_rows+= thd->examined_row_count; thd->lex->current_select= lex_select_save; DBUG_RETURN(1); } @@ -502,7 +504,10 @@ int st_select_lex_unit::exec() fake_select_lex->table_list.empty(); if (!res) + { thd->limit_found_rows = (ulonglong)table->file->records + add_rows; + thd->examined_row_count+= examined_rows; + } /* Mark for slow query log if any of the union parts didn't use indexes efficiently |