Oracle + dbunit gets AmbiguousTableNameException

前端 未结 5 1952
眼角桃花
眼角桃花 2021-01-02 09:28

I am using dbunit to create database backups, which can be imported and exported. My application can use several database engines: MySQL, PostgreSQL, SQLServer, H2 and Oracl

5条回答
  •  春和景丽
    2021-01-02 09:57

    From the docs:

    public class AmbiguousTableNameException extends DataSetException

    This exception is thrown by IDataSet when multiple tables having the same name are accessible. This usually occurs when the database connection have access to multiple schemas containing identical table names.

    Possible solutions:

    1) Use a database connection credential that has access to only one database schema.

    2) Specify a schema name to the DatabaseConnection or DatabaseDataSourceConnection constructor.

    3) Enable the qualified table name support (see How-to documentation).

提交回复
热议问题