0

我试图运行 Benerator 来填充数据库(商店演示以根据设置文件填充数据库模式)。在运行以下命令时,

我收到以下错误。

15:25:50,232 INFO  (main) [DefaultDBSystem] Fetching table details and ordering tables by dependency
15:25:50,554 ERROR (main) [DescriptorRunner] Error in Benerator execution
org.databene.commons.ConfigurationError: Catalog 'myDB' not found in database 'db'
        at org.databene.platform.db.DBSystem.findTableInConfiguredCatalogAndSchema(DBSystem.java:819)
        at org.databene.platform.db.DBSystem.getTable(DBSystem.java:791)
        at org.databene.platform.db.DBSystem.getWriteColumnInfos(DBSystem.java:744)
        at org.databene.platform.db.DBSystem.persistOrUpdate(DBSystem.java:831)
        at org.databene.platform.db.DBSystem.store(DBSystem.java:360)
        at org.databene.benerator.storage.StorageSystemInserter.startProductConsumption(StorageSystemInserter.java:53)
        at org.databene.benerator.consumer.AbstractConsumer.startConsuming(AbstractConsumer.java:47)
        at org.databene.benerator.consumer.ConsumerProxy.startConsuming(ConsumerProxy.java:62)
        at org.databene.benerator.engine.statement.ConsumptionStatement.execute(ConsumptionStatement.java:53)
        at org.databene.benerator.engine.statement.GenerateAndConsumeTask.execute(GenerateAndConsumeTask.java:159)
        at org.databene.task.TaskProxy.execute(TaskProxy.java:59)
        at org.databene.task.StateTrackingTaskProxy.execute(StateTrackingTaskProxy.java:52)
        at org.databene.task.TaskExecutor.runWithoutPage(TaskExecutor.java:136)
        at org.databene.task.TaskExecutor.runPage(TaskExecutor.java:126)
        at org.databene.task.TaskExecutor.run(TaskExecutor.java:101)
        at org.databene.task.TaskExecutor.run(TaskExecutor.java:77)
        at org.databene.task.TaskExecutor.execute(TaskExecutor.java:71)
        at org.databene.benerator.engine.statement.GenerateOrIterateStatement.executeTask(GenerateOrIterateStatement.java:156
        at org.databene.benerator.engine.statement.GenerateOrIterateStatement.execute(GenerateOrIterateStatement.java:99)
        at org.databene.benerator.engine.statement.LazyStatement.execute(LazyStatement.java:58)
        at org.databene.benerator.engine.statement.StatementProxy.execute(StatementProxy.java:46)
        at org.databene.benerator.engine.statement.TimedGeneratorStatement.execute(TimedGeneratorStatement.java:70)
        at org.databene.benerator.engine.statement.SequentialStatement.executeSubStatements(SequentialStatement.java:52)
        at org.databene.benerator.engine.statement.SequentialStatement.execute(SequentialStatement.java:47)
        at org.databene.benerator.engine.BeneratorRootStatement.execute(BeneratorRootStatement.java:63)
        at org.databene.benerator.engine.DescriptorRunner.execute(DescriptorRunner.java:127)
        at org.databene.benerator.engine.DescriptorRunner.runWithoutShutdownHook(DescriptorRunner.java:109)
        at org.databene.benerator.engine.DescriptorRunner.run(DescriptorRunner.java:102)
        at org.databene.benerator.main.Benerator.runFile(Benerator.java:94)
        at org.databene.benerator.main.Benerator.runFromCommandLine(Benerator.java:75)
        at org.databene.benerator.main.Benerator.main(Benerator.java:68)
15:25:50,611 INFO  (main) [CachingDBImporter] Exporting Database meta data of ___temp to cache file
15:25:50,635 INFO  (main) [CONFIG] Max. committed heap size: 15 MB

在我的“db”文件夹中,我有文件 user.ben.xml,它的开头是,

<database id="db" url="jdbc:oracle:thin:@localhost:1521:mirev" driver="oracle.jdbc.driver.OracleDriver" user="myDB" tableFilter="DB_.*" />

我是 Benerator 的新手。谁能告诉我为什么会抛出这个错误。

4

2 回答 2

0

默认情况下,Oracle DB 不支持“目录”。确保您的数据库启用并定义了目录。如果没有,则从您的配置中删除目录。

于 2016-11-11T10:23:46.977 回答
-1

我今天也尝试了同样的方法...看来 oracle 用户/模式(= jdbc 术语中的目录)需要首先按字母顺序排列才能使示例正常工作。我创建了一个用户“A1000”来使示例工作。

于 2015-09-05T13:13:50.253 回答