[CONJ-890] getImportedKeys/getTables regression returning an empty resultset for null/empty catalog Created: 2021-06-23 Updated: 2021-06-29 Resolved: 2021-06-29 |
|
| Status: | Closed |
| Project: | MariaDB Connector/J |
| Component/s: | metadata |
| Affects Version/s: | 2.7.3 |
| Fix Version/s: | 2.7.4 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Abdul Mohammed | Assignee: | Diego Dupin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | metadata | ||
| Description |
|
I would like report an issue encountered with mariadb-java-client version 2.7.3 where getting foreign keys via getImportedKeysUsingInformationSchema is returning null values which up until 2.7.2 is still working as expected. I work for Alfresco Software and we create a table as:
with it's schema as:
and use java.sql.DatabaseMetaData interface's getImportedKeys method which is implemented by mariadb-java-client:2.7.3's getImportedKeys and subsequently it uses getImportedKeysUsingInformationSchema. I believe a change due to CONJ-880 may have broken how foreign keys are returned and this commit seems to be related to it. When the schema is checked against the database, it seems all the foreign keys are returned as null and debugging hinted me below issue:
I couldn't find a working solution or a workaround to fix this. However, I also noted in your next release 3.0.0-alpha this problem is fixed and foreign keys are listed as normal. However, I wanted to report this issue explicitly for 2.7.3. I used MariaDB server versions: 10.2.18 and 10.3.4 using MariaDB's docker images to reproduce this issue. |
| Comments |
| Comment by Diego Dupin [ 2021-06-29 ] |
|
issue reproduced. |