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

PK_NAME returned by DatabaseMetadata.getPrimaryKeys() should not be null

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 1.5.8, 1.5.9
    • 1.6.1, 2.0.2
    • None
    • For MariaDB, driver version ="1.5.8" and "1.5.9",
      Maria DB server version: MariaDB 10.2.4 RC
      OS: windows 10

    Description

      PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null

      For MariaDB, driver version ="1.5.8" and "1.5.9",
      Maria DB server version: MariaDB 10.2.4 RC

      DatabaseMetadata.getPrimaryKeys() returns PK_NAME as null, which is incorrect.

      https://mariadb.com/kb/en/mariadb/create-table/, please note that constraint names cannot be defined by the user.

      This bug breaks IBM Cognos' mutual customers to generate relationship based on primary keys and foreign keys.

      Attachments

        Activity

          zhuq QING ZHU created issue -
          zhuq QING ZHU made changes -
          Field Original Value New Value
          Description PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null
          PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null

          For MariaDB, driver version ="1.5.8" and "1.5.9",
          Maria DB server version: MariaDB 10.2.4 RC

          DatabaseMetadata.getPrimaryKeys() returns PK_NAME as null, which is not correct.

          https://mariadb.com/kb/en/mariadb/create-table/, please note that constraint names cannot be defined by the user.

          This bug breaks IBM Cognos' mutual customers to generate relationship based on primary keys and foreign keys.
          PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null

          For MariaDB, driver version ="1.5.8" and "1.5.9",
          Maria DB server version: MariaDB 10.2.4 RC

          DatabaseMetadata.getPrimaryKeys() returns PK_NAME as null, which is not correct.

          https://mariadb.com/kb/en/mariadb/create-table/, please note that constraint names cannot be defined by the user.

          This bug breaks IBM Cognos' mutual customers to generate relationship based on primary keys and foreign keys.
          Summary PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null PK_NAME returned by DatabaseMetadata.getPrimaryKeys() should not be null
          zhuq QING ZHU made changes -
          Description PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null

          For MariaDB, driver version ="1.5.8" and "1.5.9",
          Maria DB server version: MariaDB 10.2.4 RC

          DatabaseMetadata.getPrimaryKeys() returns PK_NAME as null, which is not correct.

          https://mariadb.com/kb/en/mariadb/create-table/, please note that constraint names cannot be defined by the user.

          This bug breaks IBM Cognos' mutual customers to generate relationship based on primary keys and foreign keys.
          PK_NAME returned in DatabaseMetadata.getPrimaryKeys() should not be null

          For MariaDB, driver version ="1.5.8" and "1.5.9",
          Maria DB server version: MariaDB 10.2.4 RC

          DatabaseMetadata.getPrimaryKeys() returns PK_NAME as null, which is incorrect.

          https://mariadb.com/kb/en/mariadb/create-table/, please note that constraint names cannot be defined by the user.

          This bug breaks IBM Cognos' mutual customers to generate relationship based on primary keys and foreign keys.
          diego dupin Diego Dupin added a comment - - edited

          Hi zhuq.
          Right, PK_NAME must always return INDEX_NAME values (that is always set to 'PRIMARY').

          diego dupin Diego Dupin added a comment - - edited Hi zhuq . Right, PK_NAME must always return INDEX_NAME values (that is always set to 'PRIMARY').
          diego dupin Diego Dupin made changes -
          Fix Version/s 1.6.1 [ 22550 ]
          Fix Version/s 2.0.2 [ 22551 ]
          diego dupin Diego Dupin made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          diego dupin Diego Dupin made changes -
          Resolution Fixed [ 1 ]
          Status In Progress [ 3 ] Closed [ 6 ]
          zhuq QING ZHU added a comment -

          Hi diego dupin, I see this issue has been fixed in JDBC version 1.6.1 and 2.0.2. Is that correct? If so, where to download the fixed JDBC drivers? Thanks.

          zhuq QING ZHU added a comment - Hi diego dupin, I see this issue has been fixed in JDBC version 1.6.1 and 2.0.2. Is that correct? If so, where to download the fixed JDBC drivers? Thanks.
          diego dupin Diego Dupin added a comment -

          They will be released in a few days,

          Snapshot are available though :

          <repositories>
              <repository>
                  <id>sonatype-nexus-snapshots</id>
                  <name>Sonatype Nexus Snapshots</name>
                  <url>https://oss.sonatype.org/content/repositories/snapshots</url>
              </repository>
          </repositories>
           
          <dependencies>
              <dependency>
                  <groupId>org.mariadb.jdbc</groupId>
                  <artifactId>mariadb-java-client</artifactId>
                  <version>2.0.2-SNAPSHOT</version>
              </dependency>
          </dependencies>
          

          diego dupin Diego Dupin added a comment - They will be released in a few days, Snapshot are available though : <repositories> <repository> <id>sonatype-nexus-snapshots</id> <name>Sonatype Nexus Snapshots</name> <url>https: //oss.sonatype.org/content/repositories/snapshots</url> </repository> </repositories> <dependencies> <dependency> <groupId>org.mariadb.jdbc</groupId> <artifactId>mariadb-java-client</artifactId> <version> 2.0 . 2 -SNAPSHOT</version> </dependency> </dependencies>
          serg Sergei Golubchik made changes -
          Workflow MariaDB v3 [ 80786 ] MariaDB v4 [ 134978 ]

          People

            diego dupin Diego Dupin
            zhuq QING ZHU
            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.