1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-5.0

into rurik.mysql.com:/home/igor/mysql-5.0


mysql-test/r/distinct.result:
  Auto merged
mysql-test/t/distinct.test:
  Auto merged
sql/sql_select.cc:
  Auto merged
This commit is contained in:
unknown
2005-08-22 09:40:10 -07:00
2 changed files with 8 additions and 360 deletions

View File

@ -464,6 +464,14 @@ SELECT DISTINCT html,SUM(rout)/(SUM(rin)+1) as 'prod' FROM t1 GROUP BY rin;
html prod
1 0.0000
drop table t1;
create table t1 (id int, dsc varchar(50));
insert into t1 values (1, "line number one"), (2, "line number two"), (3, "line number three");
select distinct id, IFNULL(dsc, '-') from t1;
id IFNULL(dsc, '-')
1 line number one
2 line number two
3 line number three
drop table t1;
CREATE TABLE t1 (a int);
INSERT INTO t1 VALUES (1),(2),(3),(4),(5);
SELECT DISTINCT a, 1 FROM t1;