Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Java] Populate JDBC schema name metadata when config.shouldIncludeMetadata provided #32900

Closed
asfimport opened this issue Sep 9, 2022 · 1 comment

Comments

@asfimport
Copy link
Collaborator

Current implementation include catalog,table,column,type metadata, but schema metadata field is missing. In terms of PostgreSQL catalog - is database, schema - namespace inside database, so catalog name is insufficient for table addressing without schema.

 

Proposed changes is:

metadata.put(Constants.SQL_CATALOG_NAME_KEY, rsmd.getCatalogName(i));
metadata.put(Constants.SQL_SCHEMA_KEY, rsmd.getSchemaName(i));
metadata.put(Constants.SQL_TABLE_NAME_KEY, rsmd.getTableName(i));
metadata.put(Constants.SQL_COLUMN_NAME_KEY, columnName);
metadata.put(Constants.SQL_TYPE_KEY, rsmd.getColumnTypeName(i));

But this fix required to change assertions for metadata checks in many tests in arrow-jdbc module

Reporter: Igor Suhorukov / @igor-suhorukov
Assignee: Igor Suhorukov / @igor-suhorukov

PRs and other links:

Note: This issue was originally created as ARROW-17659. Please see the migration documentation for further details.

@asfimport
Copy link
Collaborator Author

David Li / @lidavidm:
Issue resolved by pull request 14196
#14196

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant