Details
-
Bug
-
Status: Resolved
-
Blocker
-
Resolution: Fixed
-
Impala 2.0
-
None
-
None
-
commit 8f4b29c79439be184a4c8b8835b7c2127722ce2a
Author: Lenni Kuff <lskuff@cloudera.com>
Date: Wed Oct 1 16:27:35 2014 -0700
Support specifying KW_ROLE in GRANT/REVOKE
Description
The top two queries have incorrect results. It looks like there is some sort of data corruption. The bottom query using CHAR(5) is fine.
[localhost.localdomain:21000] > select t1.vc, COUNT(1) FROM chars_tiny t1 GROUP BY 1; Query: select t1.vc, COUNT(1) FROM chars_tiny t1 GROUP BY 1 +------+----------+ | vc | count(1) | +------+----------+ | NULL | 1 | | 3ccc | 1 | | | 2 | | | 1 | | | 1 | | | 1 | | | 1 | | | 1 | +------+----------+ Fetched 8 row(s) in 0.57s [localhost.localdomain:21000] > select t1.cl, COUNT(1) FROM chars_tiny t1 GROUP BY 1; Query: select t1.cl, COUNT(1) FROM chars_tiny t1 GROUP BY 1 +--------------------------+----------+ | cl | count(1) | +--------------------------+----------+ | @ | 1 | | �` | | | �� | | | �� | | | � | | | A��@ | 1 | | �` | | | �� | | | � | | | �@��A��@ | 1 | | �` | | | � | | | �@���@��A��@ | 1 | | � | | | �@���@���@��A�� | 1 | | NULL | 1 | | �@���@���@�� | 2 | | @@���@���@�� | 1 | +--------------------------+----------+ Fetched 8 row(s) in 0.46s [localhost.localdomain:21000] > select t1.cs, COUNT(1) FROM chars_tiny t1 GROUP BY 1; Query: select t1.cs, COUNT(1) FROM chars_tiny t1 GROUP BY 1 +-------+----------+ | cs | count(1) | +-------+----------+ | 2aaaa | 1 | | 6a | 2 | | 4aa | 1 | | a | 1 | | 1aaaa | 1 | | NULL | 1 | | 3aaa | 1 | | 5a | 1 | +-------+----------+ Fetched 8 row(s) in 0.46s
Postgresql
functional=# select t1.vc, COUNT(1) FROM chars_tiny t1 GROUP BY 1; vc | count ---------+------- | 1 2cccccc | 1 4cc | 1 5c | 1 6c | 2 c | 1 1cccc | 1 3ccc | 1 (8 rows) functional=# select t1.cl, COUNT(1) FROM chars_tiny t1 GROUP BY 1; cl | count -------------------------------------------------------------------------------------------- --------------------------------------------------+------- | 1 b | 1 2bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb | 1 4bbbb | 1 1bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb | 1 3bbbbb | 1 6b | 2 5bbb | 1 (8 rows) functional=# select t1.cs, COUNT(1) FROM chars_tiny t1 GROUP BY 1; cs | count -------+------- 2aaaa | 1 | 1 6a | 2 a | 1 5a | 1 1aaaa | 1 3aaa | 1 4aa | 1 (8 rows)