You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kylin.apache.org by "Ted Yu (JIRA)" <ji...@apache.org> on 2017/07/06 01:01:00 UTC
[jira] [Comment Edited] (KYLIN-2643) PreparedStatement should be
closed in QueryServiceV2#execute()
[ https://issues.apache.org/jira/browse/KYLIN-2643?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16039530#comment-16039530 ]
Ted Yu edited comment on KYLIN-2643 at 7/6/17 1:00 AM:
-------------------------------------------------------
AdHocRunnerJdbcImpl#executeQuery() should close statement upon return .
was (Author: yuzhihong@gmail.com):
AdHocRunnerJdbcImpl#executeQuery() should close statement upon return.
> PreparedStatement should be closed in QueryServiceV2#execute()
> --------------------------------------------------------------
>
> Key: KYLIN-2643
> URL: https://issues.apache.org/jira/browse/KYLIN-2643
> Project: Kylin
> Issue Type: Bug
> Reporter: Ted Yu
> Assignee: Yifan Zhang
> Priority: Minor
> Labels: newbie, scope
>
> {code}
> PreparedStatement preparedState = conn.prepareStatement(correctedSql);
> processStatementAttr(preparedState, sqlRequest);
> for (int i = 0; i < ((PrepareSqlRequest) sqlRequest).getParams().length; i++) {
> setParam(preparedState, i + 1, ((PrepareSqlRequest) sqlRequest).getParams()[i]);
> }
> resultSet = preparedState.executeQuery();
> {code}
> preparedState should be closed upon returning from the method.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)