小编Dan*_*aes的帖子

如何使用hibernate4-maven-plugin生成多个方言模式?

我想使用hibernate4-maven-plugin在SQL中生成数据库模式.

但我有一个条件:我想生成3个模式:

  • 一个用于Postgres,
  • 一个用于Oracle和
  • 另一个用于SQL Server.

这是我的配置:

<plugin>
    <groupId>de.juplo</groupId>
    <artifactId>hibernate4-maven-plugin</artifactId>
    <version>1.0.3</version>
    <executions>
        <execution>
            <goals>
                <goal>export</goal>
            </goals>
        </execution>
    </executions>
    <configuration>
        <hibernateDialect>org.hibernate.dialect.PostgreSQLDialect</hibernateDialect>

        <!-- I want generate the schemas for these dialects too, at same time... -->
        <!-- <hibernateDialect>org.hibernate.dialect.Oracle10gDialect</hibernateDialect>-->
        <!-- <hibernateDialect>org.hibernate.dialect.SQLServerDialect</hibernateDialect>-->

        <target>SCRIPT</target>
    </configuration>
</plugin>
Run Code Online (Sandbox Code Playgroud)

我看一下官方文档(上面的链接),但是不清楚它是否可能.

有一种方法可以用hibernate4-maven-plugin做到这一点?

谢谢!

java sql hibernate maven-plugin maven

2
推荐指数
1
解决办法
3985
查看次数

标签 统计

hibernate ×1

java ×1

maven ×1

maven-plugin ×1

sql ×1