diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2022-07-27 17:17:24 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2022-07-27 17:17:24 +0300 |
commit | 098c0f2634a35e24e9eb0f06d3fba69d0d097657 (patch) | |
tree | 8e6b460d1c8812d29444bf1bd7449e5871105215 /sql/sql_type.cc | |
parent | 5bf4dee36943cb4cc95d10863d469192de854800 (diff) | |
parent | e5c4f4e590d7782ef938b436f84ae11b68e0af08 (diff) | |
download | mariadb-git-098c0f2634a35e24e9eb0f06d3fba69d0d097657.tar.gz |
Merge 10.4 into 10.5
Diffstat (limited to 'sql/sql_type.cc')
-rw-r--r-- | sql/sql_type.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/sql_type.cc b/sql/sql_type.cc index 1473d82ff75..15ccb4e1d98 100644 --- a/sql/sql_type.cc +++ b/sql/sql_type.cc @@ -1,5 +1,5 @@ /* - Copyright (c) 2015, 2021, MariaDB + Copyright (c) 2015, 2022, MariaDB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -1957,6 +1957,9 @@ Type_collection_std::aggregate_for_comparison(const Type_handler *ha, return ha; } } + if ((a == INT_RESULT && b == STRING_RESULT) || + (b == INT_RESULT && a == STRING_RESULT)) + return &type_handler_newdecimal; if ((a == INT_RESULT || a == DECIMAL_RESULT) && (b == INT_RESULT || b == DECIMAL_RESULT)) return &type_handler_newdecimal; |