db-ddlutils-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Dudziak" <tom...@gmail.com>
Subject Re: Selective Export
Date Fri, 19 Jan 2007 03:08:21 GMT
On 1/15/07, Laurent ROCHE <laurent_roche@yahoo.com> wrote:

> I am trying to export only a part of my data from PostgreSQL to Derby.
> I am using the Ant tasks of DDL Utils.
>
> Ideally, what I would like to do is to be able to run DDL-Utils export data on a SQL
request not tables.
> Nearly as good, will be to run DDL-Utils on a view (I will have to create the view and
drop the view when finished).
>
> Tom told me on this mailing list (on Dec. 14th):
> DdlUtils currently cannot create views (though it can read from them
> if VIEW is included in the table types (a parameter of the Ant task).
> I thought it meant that DDL-Utils will not manage schema but data. But from my tests,
it seems that DDL-Utils does not manage data for views (i.e. does not export data, as import
for views won't mean much), and exports the schema with views.

In order to be able to read data from views, you probably have to
specify "TABLE, VIEW" for the tabletypes parameter
(http://db.apache.org/ddlutils/ant/org.apache.ddlutils.task.DatabaseToDdlTask.html#parameter-tabletypes).
If that doesn't work, then could you please use the dumpMetadata task
(http://db.apache.org/ddlutils/ant/org.apache.ddlutils.task.DumpMetadataTask.html)
on this database (schema) and send me the file so that I can see what
table types the database reports for the views ?

> But when importing the schema, despite the messages stating creation of tables (with
the views names) nothing is created. Am I correct with this ? Is this the normal behaviour
or am I doing something wrong ?

If they are in the schema XML, then this should work (though DdlUtils
will create normal tables, not views).

Tom

Mime
View raw message