[
https://issues.apache.org/jira/browse/DRILL-205?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Ben Becker resolved DRILL-205.
------------------------------
Resolution: Duplicate
Target Version/s: (was: M1)
Closing out as a duplicate of DRILL-209; although the manifestation is
different, the root cause is the same.
Note that you may also need to remove the .classpath file in the drill
directory after applying the patch from DRILL-209. Please feel free to reopen
if this does not solve the issue.
> SELECT DISTINCT fails on char column
> ------------------------------------
>
> Key: DRILL-205
> URL: https://issues.apache.org/jira/browse/DRILL-205
> Project: Apache Drill
> Issue Type: Bug
> Environment: drill-root-1.0.0-m1
> Reporter: Harri Kinnunen
> Assignee: Ben Becker
>
> This works:
> SELECT distinct nation.name
> FROM (
> SELECT _MAP['N_REGIONKEY'] as name
> FROM "sample-data/nation.parquet"
> ) nation;
> This fails (the difference is the 'N_NAME'):
> SELECT distinct nation.name
> FROM (
> SELECT _MAP['N_NAME'] as name
> FROM "sample-data/nation.parquet"
> ) nation;
> java.lang.IndexOutOfBoundsException: index: 7, length: 2 (expected: range(0,
> 7))
> at io.netty.buffer.AbstractByteBuf.checkIndex(AbstractByteBuf.java:1130)
> at io.netty.buffer.SlicedByteBuf.getBytes(SlicedByteBuf.java:171)
> at
> org.apache.drill.exec.vector.VarBinaryVector$Accessor.get(VarBinaryVector.java:234)
> at
> org.apache.drill.exec.vector.VarBinaryVector$Accessor.getObject(VarBinaryVector.java:251)
> at
> org.apache.drill.sql.client.full.BatchLoaderMap.getObj(BatchLoaderMap.java:116)
> at
> org.apache.drill.sql.client.full.BatchLoaderMap.getCurrentObject(BatchLoaderMap.java:97)
> at
> org.apache.drill.sql.client.full.ResultEnumerator.moveNext(ResultEnumerator.java:34)
> at
> net.hydromatic.optiq.runtime.ObjectEnumeratorCursor.next(ObjectEnumeratorCursor.java:44)
> at
> net.hydromatic.optiq.jdbc.OptiqResultSet.next(OptiqResultSet.java:162)
> at sqlline.SqlLine$BufferedRows.<init>(SqlLine.java:2499)
> at sqlline.SqlLine.print(SqlLine.java:1886)
> at sqlline.SqlLine$Commands.execute(SqlLine.java:3835)
> at sqlline.SqlLine$Commands.sql(SqlLine.java:3738)
> at sqlline.SqlLine.dispatch(SqlLine.java:882)
> at sqlline.SqlLine.begin(SqlLine.java:717)
> at sqlline.SqlLine.mainWithInputRedirection(SqlLine.java:460)
> at sqlline.SqlLine.main(SqlLine.java:443)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira