You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "YeongWei (JIRA)" <ji...@apache.org> on 2015/04/02 15:30:13 UTC

[jira] [Commented] (CALCITE-646) AvaticaStatement execute method unable to work in Remote JDBC

    [ https://issues.apache.org/jira/browse/CALCITE-646?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14392621#comment-14392621 ] 

YeongWei commented on CALCITE-646:
----------------------------------

1) Execute() will need to know the statement types (E.g. INSERT, UPDATE, DELETE, CREATE, etc) to determine if it should fire the executeQuery() or executeUpdate(). Therefore the execute() method should be a higher abstraction compared to executeQuery() and executeUpdate(). Looking at the commits from CALCITE-636, the AvaticaStatement.execute does not seems to be doing such statement type check and it relies on the ResultSet#isClosed to return the valid boolean result. 
2) Currently exploring the SqlNode#getKind to evaluate if it is sufficient enough inform the statement type. Which may be obtained during the CalciteConnectionImpl#parseQuery routine. 

Any comments ?

> AvaticaStatement execute method unable to work in Remote JDBC
> -------------------------------------------------------------
>
>                 Key: CALCITE-646
>                 URL: https://issues.apache.org/jira/browse/CALCITE-646
>             Project: Calcite
>          Issue Type: Bug
>    Affects Versions: 1.1.0-incubating
>            Reporter: YeongWei
>            Assignee: Julian Hyde
>         Attachments: CALCITE-646.patch
>
>
> 1) Tested with Java source code.
> 2) Tested with Apache Squirrel.
> On AvaticaStatement.execute routine, it is not calling the prepareAndExecuteInternal instead it is calling the executeQueryInternal which misses the remote execution call.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)