summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2011-08-22 13:38:32 +0200
committerSergei Golubchik <sergii@pisem.net>2011-08-22 13:38:32 +0200
commit5dc1a2231f55bacc9aaf0e24816f3d9c2ee1f21d (patch)
tree15cc0992060f7813657ae6e47c886ade595da1ff /sql
parentaab970f5e16a1dbb308cfc13d47d3b863143811f (diff)
downloadmariadb-git-5dc1a2231f55bacc9aaf0e24816f3d9c2ee1f21d.tar.gz
lp:822760 Wrong result with view + invalid dates
sql/sql_select.cc: items' cmp_type()'s must match, not result_type()'s
Diffstat (limited to 'sql')
-rw-r--r--sql/sql_select.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index 20b0b1a60f2..6d2c7400d3d 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -11627,7 +11627,7 @@ propagate_cond_constants(THD *thd, I_List<COND_CMP> *save_list,
bool left_const= args[0]->const_item() && !args[0]->is_expensive();
bool right_const= args[1]->const_item() && !args[1]->is_expensive();
if (!(left_const && right_const) &&
- args[0]->result_type() == args[1]->result_type())
+ args[0]->cmp_type() == args[1]->cmp_type())
{
if (right_const)
{