diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-06-18 11:30:06 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-06-18 11:30:06 +0300 |
commit | 3c88ce4cd112f696002d5f7461db68a3dafeb838 (patch) | |
tree | 8860f823877b8d816fbca45d9e6926bcbc8f012d /sql/sql_lex.cc | |
parent | 44d06cd39df2bdde6f7ac31d5340f1f683683c99 (diff) | |
parent | e85e4814eeca9123b23c23b40dd776416bfba2ca (diff) | |
download | mariadb-git-3c88ce4cd112f696002d5f7461db68a3dafeb838.tar.gz |
Merge 10.4 into 10.5
Diffstat (limited to 'sql/sql_lex.cc')
-rw-r--r-- | sql/sql_lex.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index c6140e35b24..a2cfc0d0128 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -4862,7 +4862,10 @@ void SELECT_LEX::increase_derived_records(ha_rows records) break; default: // usual UNION - result->est_records+= records; + if (HA_ROWS_MAX - records > result->est_records) + result->est_records+= records; + else + result->est_records= HA_ROWS_MAX; break; } } |