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

GenericTableMetaDataProvider could use non standard named TableMeta-Schema if only one found [SPR-15090] #19656

spring-issuemaster opened this issue Jan 4, 2017 · 1 comment


Copy link

commented Jan 4, 2017

Uwe Grünheid opened SPR-15090 and commented

Use Case

  1. Postgres 9.5 accessed via spring DatabaseBuilder and URL including currentSchema(since Postgres 9.4)
  2. Spring Batch accessing database using spring jdbc (JdbcTemplate, etc)
  3. SimpleJdbcInsert using doExecuteAndReturnKey(SqlParameterSource parameterSource)


  1. method locateTableAndProcessMetaData fills tableMeta with schema from given table (see on picture)
    • tmd.setSchemaName(tables.getString("TABLE_SCHEM")); (line. 308)
  2. Afterwards fetching tableMeta fails because it checks for default schema or known database schemas like PUBLIC or DBO
  3. DataAccessResourceFailureException is thrown


If no standard schema fits and tableMeta has size 1 use the schema found by selecting table meta data.

Affects: 4.2.6

Reference URL:


Referenced from: commits de7eea4, de43497


This comment has been minimized.

Copy link
Collaborator Author

commented Jan 12, 2017

Uwe Grünheid commented

Thanks for fast handling ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.