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

MySQL Connector Incompatible result from Statement.executeQuery when executing DDL

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Won't Fix
    • 3.1.2
    • N/A
    • MySQL compatibility
    • None
    • Windows 11
      MariaDB Connector 3.1.2
      MySQL Connector 8.0.32
      MariaDB 10.11

    Description

      Hey there,

      I use different connectors(MySQL / MariaDB Connector) to connect to the same MariaDB. My connection URL is like "jdbc:mariadb://localhost:3366/test?useUnicode=true&characterEncoding=utf8&sessionVariables=storage_engine=InnoDB,sql_mode=''&connectionTimeZone=UTC" and "jdbc:mysql://localhost:3366/test?useUnicode=true&characterEncoding=utf8&sessionVariables=storage_engine=InnoDB,sql_mode=''&connectionTimeZone=UTC"

      and the setup SQL file:

      DROP DATABASE IF EXISTS database0;
      CREATE DATABASE database0;
      

      I execute this file using Statement.executeQuery() for both connectors.

      But the MySQL Connector and MariaDB Connector seem to have different results when executing the SQL file.
      That is, MySQL Connector returns 'java.sql.SQLException: Statement.executeQuery() cannot issue statements that do not produce result sets.' but MariaDB Connector can successfully execute these SQLs and returns an empty result.

      I also classify this as a bug because MariaDB claims MySQL compatibility at the driver level.

      Attachments

        Activity

          People

            diego dupin Diego Dupin
            dwenking Wenqian Deng
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.