【问题标题】:Liquibase generateChangeLog creates empty log fileLiquibase generateChangeLog 创建空日志文件
【发布时间】:2018-10-23 09:03:21
【问题描述】:

我正在尝试运行 generateChangeLog 以获取数据库架构的当前结构。但是,我看到 liquibase 总是返回空文件。

$ liquibase --logLevel=debug --driver=oracle.jdbc.OracleDriver --classpath="C:\temp\ojdbc8.jar" --changeLogFile="C:\db-changelog.xml" --url="jdbc:oracle:thin:@localhost:1521:xe" --username=system --password=oracle  --defaultSchemaName=system generateChangeLog

Starting Liquibase at Tue, 23 Oct 2018 14:16:42 IST (version 3.6.2 built at 2018-07-03 11:28:09)
Liquibase command 'generateChangeLog' was executed successfully.

另外,虽然我已将日志级别指定为调试,但我没有看到 liquibase 生成日志。

感谢任何帮助。

谢谢

【问题讨论】:

  • 文件夹中是否生成了名为databasechangelog.csv的csv文件?

标签: liquibase


【解决方案1】:

我遇到了同样的问题,在数据库URL中添加方案名称后解决了:

?currentSchema=core

命令示例:

$ liquibase --driver=org.postgresql.Driver \
     --classpath=postgresql-42.2.5.jar \
     --username=postgres \
     --password=postgres \
     --url="jdbc:postgresql://localhost:5432/data?currentSchema=core" \
     --changeLogFile=changelog-output.xml \
     generateChangeLog

Liquibase 版本:3.7.0

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2021-10-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-09-10
    • 1970-01-01
    • 2021-11-06
    • 2011-11-12
    相关资源
    最近更新 更多