Uploaded image for project: 'Phoenix'
  1. Phoenix
  2. PHOENIX-3104 Enable Phoenix test cases with Calcite-Phoenix
  3. PHOENIX-3674

Upsert or Delele queries failing to translate LogicalTableModify into MutableRel in Phoenix-Calcite

    XMLWordPrintableJSON

    Details

    • Type: Sub-task
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Here are the tests failing

      testDeleteAllFromTableWithLocalIndexNoAutoCommitSalted(org.apache.phoenix.end2end.DeleteIT)  Time elapsed: 8.99 sec  <<< ERROR!
      java.sql.SQLException: Error while executing SQL "DELETE FROM T000139": cannot translate rel#7748:LogicalTableModify.NONE.[](input=rel#7735:PhoenixTableScan.SERVER.[](table=[phoenix, T000139]),table=[phoenix, T000139],operation=DELETE,flattened=false) to MutableRel
      	at org.apache.phoenix.end2end.DeleteIT.testDeleteAllFromTableWithIndex(DeleteIT.java:332)
      	at org.apache.phoenix.end2end.DeleteIT.testDeleteAllFromTableWithLocalIndexNoAutoCommitSalted(DeleteIT.java:283)
      Caused by: java.lang.RuntimeException: cannot translate rel#7748:LogicalTableModify.NONE.[](input=rel#7735:PhoenixTableScan.SERVER.[](table=[phoenix, T000139]),table=[phoenix, T000139],operation=DELETE,flattened=false) to MutableRel
      	at org.apache.phoenix.end2end.DeleteIT.testDeleteAllFromTableWithIndex(DeleteIT.java:332)
      	at org.apache.phoenix.end2end.DeleteIT.testDeleteAllFromTableWithLocalIndexNoAutoCommitSalted(DeleteIT.java:283)
      
      java.sql.SQLException: Error while executing SQL "UPSERT INTO atable(organization_id,entity_id,a_integer) SELECT organization_id, entity_id, CAST(null AS integer) FROM atable": cannot translate rel#25411:LogicalTableModify.NONE.[](input=rel#25415:LogicalProject.NONE.[](input=rel#25389:PhoenixTableScan.SERVER.[](table=[phoenix, ATABLE]),ORGANIZATION_ID=$0,ENTITY_ID=$1,A_STRING=null,B_STRING=null,A_INTEGER=null,A_DATE=null,A_TIME=null,A_TIMESTAMP=null,X_DECIMAL=null,X_LONG=null,X_INTEGER=null,Y_INTEGER=null,A_BYTE=null,A_SHORT=null,A_FLOAT=null,A_DOUBLE=null,A_UNSIGNED_FLOAT=null,A_UNSIGNED_DOUBLE=null),table=[phoenix, ATABLE],operation=INSERT,flattened=false) to MutableRel
      	at org.apache.phoenix.end2end.AggregateQueryIT.testSumOverNullIntegerColumn(AggregateQueryIT.java:80)
      Caused by: java.lang.RuntimeException: cannot translate rel#25411:LogicalTableModify.NONE.[](input=rel#25415:LogicalProject.NONE.[](input=rel#25389:PhoenixTableScan.SERVER.[](table=[phoenix, ATABLE]),ORGANIZATION_ID=$0,ENTITY_ID=$1,A_STRING=null,B_STRING=null,A_INTEGER=null,A_DATE=null,A_TIME=null,A_TIMESTAMP=null,X_DECIMAL=null,X_LONG=null,X_INTEGER=null,Y_INTEGER=null,A_BYTE=null,A_SHORT=null,A_FLOAT=null,A_DOUBLE=null,A_UNSIGNED_FLOAT=null,A_UNSIGNED_DOUBLE=null),table=[phoenix, ATABLE],operation=INSERT,flattened=false) to MutableRel
      	at org.apache.phoenix.end2end.AggregateQueryIT.testSumOverNullIntegerColumn(AggregateQueryIT.java:80)
      

        Attachments

        1. PHOENIX-3674.patch
          1 kB
          Rajeshbabu Chintaguntla

          Activity

            People

            • Assignee:
              maryannxue Wei Xue
              Reporter:
              rajeshbabu Rajeshbabu Chintaguntla
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: