~ubuntu-branches/ubuntu/trusty/mariadb-5.5/trusty

« back to all changes in this revision

Viewing changes to mysql-test/r/distinct.result

  • Committer: Package Import Robot
  • Author(s): Otto Kekäläinen, Otto Kekäläinen, James Page
  • Date: 2014-03-02 01:38:26 UTC
  • mfrom: (2.1.2 sid)
  • Revision ID: package-import@ubuntu.com-20140302013826-z3afnfteqo86pccd
Tags: 5.5.36-1
[ Otto Kekäläinen ]
* New upstream release.
* Updated Danish debconf translation (Closes: #739750).
* d/control: Added explicit Conflicts/Replaces for mysql-5.6 packages
  (Closes: #739841).
* d/control: Update for use of virtual-* packages for switching to/from
  MySQL alternatives.

[ James Page ]
* d/control: Drop Nicholas from Uploaders, MIA (Closes: #739360).
* d/control: Add libjemalloc-dev to BD's.

Show diffs side-by-side

added added

removed removed

Lines of Context:
999
999
11112222
1000
1000
33334444
1001
1001
DROP TABLE t1;
 
1002
#
 
1003
# Bug#16539979 BASIC SELECT COUNT(DISTINCT ID) IS BROKEN.
 
1004
# Bug#17867117 ERROR RESULT WHEN "COUNT + DISTINCT + CASE WHEN" NEED MERGE_WALK 
 
1005
#
 
1006
SET @tmp_table_size_save= @@tmp_table_size;
 
1007
SET @@tmp_table_size= 1024;
 
1008
CREATE TABLE t1 (a INT);
 
1009
INSERT INTO t1 VALUES (1),(2),(3),(4),(5),(6),(7),(8);
 
1010
INSERT INTO t1 SELECT a+8 FROM t1;
 
1011
INSERT INTO t1 SELECT a+16 FROM t1;
 
1012
INSERT INTO t1 SELECT a+32 FROM t1;
 
1013
INSERT INTO t1 SELECT a+64 FROM t1;
 
1014
INSERT INTO t1 VALUE(NULL);
 
1015
SELECT COUNT(DISTINCT a) FROM t1;
 
1016
COUNT(DISTINCT a)
 
1017
128
 
1018
SELECT COUNT(DISTINCT (a+0)) FROM t1;
 
1019
COUNT(DISTINCT (a+0))
 
1020
128
 
1021
DROP TABLE t1;
 
1022
create table tb(
 
1023
id int auto_increment primary key,
 
1024
v varchar(32))
 
1025
engine=myisam charset=gbk;
 
1026
insert into tb(v) values("aaa");
 
1027
insert into tb(v) (select v from tb);
 
1028
insert into tb(v) (select v from tb);
 
1029
insert into tb(v) (select v from tb);
 
1030
insert into tb(v) (select v from tb);
 
1031
insert into tb(v) (select v from tb);
 
1032
insert into tb(v) (select v from tb);
 
1033
update tb set v=concat(v, id);
 
1034
select count(distinct case when id<=64 then id end) from tb;
 
1035
count(distinct case when id<=64 then id end)
 
1036
64
 
1037
select count(distinct case when id<=63 then id end) from tb;
 
1038
count(distinct case when id<=63 then id end)
 
1039
63
 
1040
drop table tb;
 
1041
SET @@tmp_table_size= @tmp_table_size_save;
1002
1042
End of 5.5 tests