Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-5629

large traceback if query attempts to use TABLESAMPLE

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 1.10.0
    • Fix Version/s: None
    • Component/s: Server
    • Labels:
      None
    • Environment:

      Drill 1.10
      ORACLE 12C2

      Description

      A plugin is defined to ORACLE

      Following statement is sent to DRILL which returns large exception response

      SELECT RNUM, C1 FROM certora.DBCERT.TOLAP TABLESAMPLE SYSTEM ( 2 ) repeatable ( 5 )

      SYSTEM ERROR: CannotPlanException: Node [rel#939863:Subset#2.LOGICAL.ANY([]).[]] could not be implemented; planner state:

      Root: rel#939863:Subset#2.LOGICAL.ANY([]).[]
      Original rel:

      Sets:
      Set#0, type: RecordType(DECIMAL(38, 0) RNUM, CHAR(3) C1, CHAR(2) C2, DECIMAL(38, 0) C3, DECIMAL(38, 0) C4)
      rel#939858:Subset#0.JDBC.certora.ANY([]).[], best=rel#939844, importance=0.7290000000000001
      rel#939844:JdbcTableScan.JDBC.certora.ANY([]).[](table=[certora, DBCERT, TOLAP]), rowcount=100.0, cumulative cost=

      {100.0 rows, 101.0 cpu, 0.0 io, 0.0 network, 0.0 memory}

      rel#939894:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939893:Subset#0.LOGICAL.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939900:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939899:Subset#0.ENUMERABLE.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939908:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939907:Subset#0.PHYSICAL.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939893:Subset#0.LOGICAL.ANY([]).[], best=rel#939892, importance=0.6561
      rel#939895:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939892:JdbcDrel.LOGICAL.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost=

      {200.0 rows, 201.0 cpu, 0.0 io, 0.0 network, 0.0 memory}
      rel#939901:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939899:Subset#0.ENUMERABLE.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939909:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939907:Subset#0.PHYSICAL.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939899:Subset#0.ENUMERABLE.ANY([]).[], best=rel#939898, importance=0.5904900000000001
      rel#939902:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939903:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939893:Subset#0.LOGICAL.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939898:JdbcToEnumerableConverter.ENUMERABLE.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost={110.0 rows, 111.0 cpu, 0.0 io, 0.0 network, 0.0 memory}
      rel#939910:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939907:Subset#0.PHYSICAL.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939907:Subset#0.PHYSICAL.ANY([]).[], best=rel#939906, importance=0.531441
      rel#939911:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939912:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939893:Subset#0.LOGICAL.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939913:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939899:Subset#0.ENUMERABLE.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}
      rel#939906:JdbcIntermediatePrel.PHYSICAL.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost={200.0 rows, 201.0 cpu, 0.0 io, 0.0 network, 0.0 memory}

      Set#1, type: RecordType(DECIMAL(38, 0) RNUM, CHAR(3) C1, CHAR(2) C2, DECIMAL(38, 0) C3, DECIMAL(38, 0) C4)
      rel#939860:Subset#1.NONE.ANY([]).[], best=null, importance=0.81
      rel#939859:Sample.NONE.ANY([]).[](input=rel#939858:Subset#0.JDBC.certora.ANY([]).[],mode=system,rate=0.02,repeatableSeed=5), rowcount=100.0, cumulative cost=

      {inf}
      rel#939865:Subset#1.JDBC.certora.ANY([]).[], best=null, importance=0.81
      rel#939889:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939888:Subset#1.LOGICAL.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939888:Subset#1.LOGICAL.ANY([]).[], best=null, importance=0.7290000000000001
      rel#939890:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939865:Subset#1.JDBC.certora.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      Set#2, type: RecordType(DECIMAL(38, 0) RNUM, CHAR(3) C1)
      rel#939862:Subset#2.NONE.ANY([]).[], best=null, importance=0.9
      rel#939861:LogicalProject.NONE.ANY([]).[](input=rel#939860:Subset#1.NONE.ANY([]).[],RNUM=$0,C1=$1), rowcount=100.0, cumulative cost={inf}

      rel#939863:Subset#2.LOGICAL.ANY([]).[], best=null, importance=1.0
      rel#939864:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939862:Subset#2.NONE.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939868:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939870:JdbcDrel.LOGICAL.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939873:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939872:Subset#2.PHYSICAL.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939880:AbstractConverter.LOGICAL.ANY([]).[](input=rel#939879:Subset#2.ENUMERABLE.ANY([]).[],convention=LOGICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939891:DrillProjectRel.LOGICAL.ANY([]).[](input=rel#939888:Subset#1.LOGICAL.ANY([]).[],RNUM=$0,C1=$1), rowcount=100.0, cumulative cost={inf}

      rel#939867:Subset#2.JDBC.certora.ANY([]).[], best=null, importance=0.9
      rel#939869:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939863:Subset#2.LOGICAL.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939866:JdbcProject.JDBC.certora.ANY([]).[](input=rel#939865:Subset#1.JDBC.certora.ANY([]).[],RNUM=$0,C1=$1), rowcount=100.0, cumulative cost={inf}

      rel#939874:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939872:Subset#2.PHYSICAL.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939881:AbstractConverter.JDBC.certora.ANY([]).[](input=rel#939879:Subset#2.ENUMERABLE.ANY([]).[],convention=JDBC.certora,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939872:Subset#2.PHYSICAL.ANY([]).[], best=null, importance=0.81
      rel#939875:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939863:Subset#2.LOGICAL.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939876:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939871:JdbcIntermediatePrel.PHYSICAL.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939882:AbstractConverter.PHYSICAL.ANY([]).[](input=rel#939879:Subset#2.ENUMERABLE.ANY([]).[],convention=PHYSICAL,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939879:Subset#2.ENUMERABLE.ANY([]).[], best=null, importance=0.7290000000000001
      rel#939883:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939863:Subset#2.LOGICAL.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939884:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost={inf}

      rel#939885:AbstractConverter.ENUMERABLE.ANY([]).[](input=rel#939872:Subset#2.PHYSICAL.ANY([]).[],convention=ENUMERABLE,DrillDistributionTraitDef=ANY([]),sort=[]), rowcount=100.0, cumulative cost=

      {inf}
      rel#939878:JdbcToEnumerableConverter.ENUMERABLE.ANY([]).[](input=rel#939867:Subset#2.JDBC.certora.ANY([]).[]), rowcount=100.0, cumulative cost={inf}

      ORACLE DDL

      CREATE TABLE "DBCERT"."TOLAP"
      ( "RNUM" NUMBER(*,0),
      "C1" CHAR(3 BYTE),
      "C2" CHAR(2 BYTE),
      "C3" NUMBER(*,0),
      "C4" NUMBER(*,0)
      ) ;
      GRANT SELECT ON "DBCERT"."TOLAP" TO PUBLIC;

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              the6campbells N Campbell
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: