You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@drill.apache.org by "Volodymyr Vysotskyi (JIRA)" <ji...@apache.org> on 2019/03/09 10:18:00 UTC
[jira] [Resolved] (DRILL-4408) re-written query projecting an
aggregate on a boolean not supported by Postgres
[ https://issues.apache.org/jira/browse/DRILL-4408?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Volodymyr Vysotskyi resolved DRILL-4408.
----------------------------------------
Resolution: Fixed
Fix Version/s: 1.16.0
Fixed in DRILL-5188
> re-written query projecting an aggregate on a boolean not supported by Postgres
> -------------------------------------------------------------------------------
>
> Key: DRILL-4408
> URL: https://issues.apache.org/jira/browse/DRILL-4408
> Project: Apache Drill
> Issue Type: Bug
> Components: Storage - JDBC
> Affects Versions: 1.5.0
> Reporter: N Campbell
> Priority: Major
> Fix For: 1.16.0
>
>
> select rnum, c1, c2 from postgres.public.tset1 as t1 where exists ( select c1 from postgres.public.tset2 where c1 = t1.c1 )
> Error: DATA_READ ERROR: The JDBC storage plugin failed while trying setup the SQL query.
> sql SELECT *
> FROM "public"."tset1"
> INNER JOIN (SELECT "c10", MIN("$f0") AS "$f1"
> FROM (SELECT "t0"."c1" AS "c10", TRUE AS "$f0"
> FROM "public"."tset2"
> INNER JOIN (SELECT "c1"
> FROM (SELECT "c1"
> FROM "public"."tset1") AS "t"
> GROUP BY "c1") AS "t0" ON "tset2"."c1" = "t0"."c1") AS "t1"
> GROUP BY "c10") AS "t2" ON "tset1"."c1" = "t2"."c10"
> plugin postgres
> Fragment 0:0
> [Error Id: a00cd446-f168-463c-b2b9-bb3d6b43e729 on centos1:31010]
> (org.postgresql.util.PSQLException) ERROR: function min(boolean) does not exist
> Hint: No function matches the given name and argument types. You might need to add explicit type casts.
> Position: 58
> org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse():2182
> org.postgresql.core.v3.QueryExecutorImpl.processResults():1911
> org.postgresql.core.v3.QueryExecutorImpl.execute():173
> org.postgresql.jdbc.PgStatement.execute():622
> org.postgresql.jdbc.PgStatement.executeWithFlags():458
> org.postgresql.jdbc.PgStatement.executeQuery():374
> org.apache.commons.dbcp.DelegatingStatement.executeQuery():208
> org.apache.commons.dbcp.DelegatingStatement.executeQuery():208
> org.apache.drill.exec.store.jdbc.JdbcRecordReader.setup():177
> org.apache.drill.exec.physical.impl.ScanBatch.<init>():108
> org.apache.drill.exec.physical.impl.ScanBatch.<init>():136
> org.apache.drill.exec.store.jdbc.JdbcBatchCreator.getBatch():40
> org.apache.drill.exec.store.jdbc.JdbcBatchCreator.getBatch():33
> org.apache.drill.exec.physical.impl.ImplCreator.getRecordBatch():147
> org.apache.drill.exec.physical.impl.ImplCreator.getChildren():170
> org.apache.drill.exec.physical.impl.ImplCreator.getRecordBatch():127
> org.apache.drill.exec.physical.impl.ImplCreator.getChildren():170
> org.apache.drill.exec.physical.impl.ImplCreator.getRecordBatch():127
> org.apache.drill.exec.physical.impl.ImplCreator.getChildren():170
> org.apache.drill.exec.physical.impl.ImplCreator.getRootExec():101
> org.apache.drill.exec.physical.impl.ImplCreator.getExec():79
> org.apache.drill.exec.work.fragment.FragmentExecutor.run():230
> org.apache.drill.common.SelfCleaningRunnable.run():38
> java.util.concurrent.ThreadPoolExecutor.runWorker():1142
> java.util.concurrent.ThreadPoolExecutor$Worker.run():617
> java.lang.Thread.run():745
> SQLState: null
> ErrorCode: 0
> create table TSET1 (RNUM integer not null , C1 integer, C2 char(3));
> create table TSET2 (RNUM integer not null , C1 integer, C2 char(3));
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)