db-ddlutils-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Dudziak" <tom...@gmail.com>
Subject Re: DatabaseToDdlTask schema attribute
Date Sat, 09 Dec 2006 19:25:05 GMT
On 12/7/06, Igor Markovic <igor-list@izecom.com> wrote:
> When I have an ant task like:
>
> ---------------------------------
> <target name="export-db-postgres" description="Dumps db structure and data">
>   <taskdef name="databaseToDdl" classname="org.apache.ddlutils.task.DatabaseToDdlTask">
>     <classpath refid="classpath"/>
>   </taskdef>
>
>   <databaseToDdl modelName="MigrateTest" schema="postgres">
>     <database url="jdbc:postgresql://localhost:5432/izemail" driverClassName="org.postgresql.Driver"
username="test" password="test"/>
>       <writeSchemaToFile outputFile="db-schema.xml"/>
>       <writeDtdToFile outputFile="db-schema.dtd"/>
>       <writeDataToFile outputFile="db-data.xml"/>
>   </databaseToDdl>
> </target>
> ---------------------------------
>
> I get the following error when running it:
>
> ---------------------------------
> Buildfile: build.xml
>
> export-db:
>
> BUILD FAILED
> C:\Temp\DdlUtils-test\build.xml:53: The <databaseToDdl> type doesn't support the
"schema" attribute.
>
> Total time: 3 seconds
> ---------------------------------
>
> But if I look at the ant documentation it says that the DatabaseToDdlTask does support
this attribute. It would be nice if it is supported so you could exclude/include tables from
export. (Or at least I thought that this attribute could do this for me).

The Ant task documentation is slightly out of date. The attribute is
now called schemapattern not schema.

Tom

Mime
View raw message