[ https://issues.apache.org/jira/browse/PHOENIX-3453?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15787802#comment-15787802 ]
Hadoop QA commented on PHOENIX-3453: ------------------------------------ {color:red}-1 overall{color}. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12845172/PHOENIX-3453_v1.patch against master branch at commit 07f92732f9c6d2d9464012cebeb4cefc10da95d5. ATTACHMENT ID: 12845172 {color:green}+1 @author{color}. The patch does not contain any @author tags. {color:green}+1 tests included{color}. The patch appears to include 3 new or modified tests. {color:green}+1 javac{color}. The applied patch does not increase the total number of javac compiler warnings. {color:red}-1 javadoc{color}. The javadoc tool appears to have generated 42 warning messages. {color:green}+1 release audit{color}. The applied patch does not increase the total number of release audit warnings. {color:red}-1 lineLengths{color}. The patch introduces the following lines longer than 100: + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+intTableName+" limit 1)"; + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+intTableName+" limit 3) order by entity_id"; + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+intTableName+" limit 3) order by entity_id desc"; + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+charTableName+" limit 3) order by entity_id"; + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+charTableName+" limit 3) order by entity_id desc"; + sql="select DISTINCT entity_id, score from ( select entity_id, score from "+tableName+" limit 1)"; + assertTrue(queryPlan.getGroupBy().getExpressions().get(0).getSortOrder()==SortOrder.DESC); + assertTrue(queryPlan.getGroupBy().getExpressions().get(1).getSortOrder()==SortOrder.DESC); + assertTrue(queryPlan.getGroupBy().getKeyExpressions().get(0).getSortOrder()==SortOrder.DESC); + assertTrue(queryPlan.getGroupBy().getKeyExpressions().get(1).getSortOrder()==SortOrder.DESC); {color:green}+1 core tests{color}. The patch passed unit tests in . Test results: https://builds.apache.org/job/PreCommit-PHOENIX-Build/713//testReport/ Javadoc warnings: https://builds.apache.org/job/PreCommit-PHOENIX-Build/713//artifact/patchprocess/patchJavadocWarnings.txt Console output: https://builds.apache.org/job/PreCommit-PHOENIX-Build/713//console This message is automatically generated. > Secondary index and query using distinct: Outer query results in ERROR 201 > (22000): Illegal data. CHAR types may only contain single byte characters > ---------------------------------------------------------------------------------------------------------------------------------------------------- > > Key: PHOENIX-3453 > URL: https://issues.apache.org/jira/browse/PHOENIX-3453 > Project: Phoenix > Issue Type: Bug > Affects Versions: 4.8.0, 4.9.0 > Reporter: Joel Palmert > Assignee: chenglei > Attachments: PHOENIX-3453_v1.patch > > > Steps to repro: > CREATE TABLE IF NOT EXISTS TEST.TEST ( > ENTITY_ID CHAR(15) NOT NULL, > SCORE DOUBLE, > CONSTRAINT TEST_PK PRIMARY KEY ( > ENTITY_ID > ) > ) VERSIONS=1, MULTI_TENANT=FALSE, REPLICATION_SCOPE=1, TTL=31536000; > CREATE INDEX IF NOT EXISTS TEST_SCORE ON TEST.TEST (SCORE DESC, ENTITY_ID > DESC); > UPSERT INTO test.test VALUES ('entity1',1.1); > SELECT DISTINCT entity_id, score > FROM( > SELECT entity_id, score > FROM test.test > LIMIT 25 > ); > Output (in SQuirreL) > ��������������� 1.1 > If you run it in SQuirreL it results in the entity_id column getting the > above error value. Notice that if you remove the secondary index or DISTINCT > you get the correct result. > I've also run the query through the Phoenix java api. Then I get the > following exception: > Caused by: java.sql.SQLException: ERROR 201 (22000): Illegal data. CHAR types > may only contain single byte characters (????????????) > at > org.apache.phoenix.exception.SQLExceptionCode$Factory$1.newException(SQLExceptionCode.java:454) > at > org.apache.phoenix.exception.SQLExceptionInfo.buildException(SQLExceptionInfo.java:145) > at > org.apache.phoenix.schema.types.PDataType.newIllegalDataException(PDataType.java:291) > at org.apache.phoenix.schema.types.PChar.toObject(PChar.java:121) > at org.apache.phoenix.schema.types.PDataType.toObject(PDataType.java:997) > at > org.apache.phoenix.compile.ExpressionProjector.getValue(ExpressionProjector.java:75) > at > org.apache.phoenix.jdbc.PhoenixResultSet.getString(PhoenixResultSet.java:608) > at > org.apache.phoenix.jdbc.PhoenixResultSet.getString(PhoenixResultSet.java:621) -- This message was sent by Atlassian JIRA (v6.3.4#6332)