summaryrefslogtreecommitdiff
path: root/mysql-test/t/udf.test
diff options
context:
space:
mode:
authorunknown <gkodinov/kgeorge@macbook.gmz>2007-01-05 14:02:50 +0200
committerunknown <gkodinov/kgeorge@macbook.gmz>2007-01-05 14:02:50 +0200
commit42e31f7a45413b685c4332ced1d983ccfda29d25 (patch)
treec950f88f3dfc18f002d2a0caa214ca6301358cd1 /mysql-test/t/udf.test
parent5df7d39e520e6b23ca2b63c0aae211fe201c4f02 (diff)
downloadmariadb-git-42e31f7a45413b685c4332ced1d983ccfda29d25.tar.gz
Bug #15881: cast problems
The optimizer removes expressions from GROUP BY/DISTINCT if they happen to participate in a <expression> = <const> predicates of the WHERE clause (the idea being that if it's always equal to a constant it can't have multiple values). However for predicates where the expression and the constant item are of different result type this is not valid (e.g. a string column compared to 0). Fixed by additional check of the result types of the expression and the constant and if they differ the expression don't get removed from the group by list. mysql-test/r/distinct.result: Bug #15881: cast problems - test case mysql-test/t/distinct.test: Bug #15881: cast problems - test case sql/sql_select.cc: Bug #15881: cast problems - can't use <expr>=<const> to remove GROUP BY/DISTINCT cols if they're not of the same type.
Diffstat (limited to 'mysql-test/t/udf.test')
0 files changed, 0 insertions, 0 deletions