Uploaded image for project: 'Kylin'
  1. Kylin
  2. KYLIN-2643

PreparedStatement should be closed in QueryServiceV2#execute()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • v2.1.0
    • Query Engine

    Description

                      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();
      

      preparedState should be closed upon returning from the method.

      Attachments

        Activity

          People

            shaofengshi Shao Feng Shi
            yuzhihong@gmail.com Ted Yu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: