On 12/7/06, Igor Markovic <[EMAIL PROTECTED]> 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

Reply via email to