Uploaded image for project: 'MariaDB Connector/J'
  1. MariaDB Connector/J
  2. CONJ-532

Statement.getMoreResults() incorrect after CREATE TABLE multiquery

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.2, 2.1.2
    • Fix Version/s: 2.2.0, 1.7.0
    • Component/s: Other
    • Labels:
      None
    • Environment:
      Ubuntu 17.04
      MariaDB Server 10.2.8

      Description

      After a query containing multiple CREATE TABLE statements Statement.getMoreResults() returns true
      for second result (indicating the result is a result set) and Statement.getResultSet() then returns null. The getMoreResults() should be false and a getUpdateCount() should then return 0 (indicating an update count of 0 is the result).

      The attached program demonstrates the bug. Correct output should show two update counts of zero. Actual output shows an update count of zero followed by a result set which is null.

      Attached program works correctly with mysql-connector-java-5.1.42.

      The problem also occurs for DROP TABLE statements.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              diego dupin Diego Dupin
              Reporter:
              colin.chambers Colin Chambers
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: