db-ddlutils-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurent ROCHE <laurent_ro...@yahoo.com>
Subject View problems [Was Not much info with: "Could not parse or write data file"]
Date Wed, 13 Dec 2006 18:43:17 GMT

I am not sure whether this is related to the data error message (see below) but I've just
noticed that a view that is present in my PostgreSQL db is not present in my Derby db.

All data seems to be there though !

Have fun,
The Travelling Froggy

----- Message d'origine ----
De : Laurent ROCHE <laurent_roche@yahoo.com>
À : ddlutils-user@db.apache.org
Cc : Jean T. Anderson <jta@bristowhill.com>
Envoyé le : Mercredi, 13 Décembre 2006, 18h20mn 27s
Objet : Re : Not much info with: "Could not parse or write data file"


Yes, the file does exist.
I should have said that I have managed to make it work previously with a tiny version of the
database, but as soon as I take the full db, the import fails. 
Also DB-unit manages to import the data without failing.

There's no error message in derby.log, last line is:
Chargeur de classe de la base de données démarré - derby.database.classpath=''
(excuse my French ;-) ! )

The schema makes sense in dblook, Cloudscape Workbench, Squirrel, ...

I still need a way to find out what the IMPORT error is !

The Computing Froggy

----- Message d'origine ----
De : Jean T. Anderson <jta@bristowhill.com>
À : ddlutils-user@db.apache.org
Envoyé le : Mercredi, 13 Décembre 2006, 17h51mn 06s
Objet : Re: Not much info with: "Could not parse or write data file"

Laurent ROCHE wrote:
> Hi,
> I am exporting a database from PostgreSQL into Derby, using the ant tasks.
> The schema has been generated OK.
> So it seems, anyway: I had the following messages:
> [ddlToDatabase] INFO: Executed 190 SQL command(s) with 0 error(s)
> [ddlToDatabase] Written schema to database
> But then the data import (I guess) fails with the following messages:
> C:\apps\Ddlutils-test\build.xml:35: Could not parse or write data file C:\apps\Ddlutils-test\data.xml

Does that data.xml file actually exist in C:\apps\Ddlutils-test\data.xml ?

> It will be nice to get an  line number where the import fails and also the SQL error
(as I suppose, it fails because of some SQL problems).
> Like this it makes it really hard to know what's going wrong ... particularly considering
the data are exported from an identical PG db (so there should be no problems).

If a SQL error is involved, a message might have been written to the
Derby log file. Assuming that you created the Derby database in
C:\apps\Ddlutils-test, check C:\apps\Ddlutils-test\derby.log.

Does the Derby schema "make sense"?  After creating the schema in Derby
you can check it with this Derby command ('dbname' is the name of your
database and this assumes you're executing this command in

java org.apache.derby.tools.dblook -d jdbc:derby:dbname -o dbname.sql

These database locations and urls assume you're using the embedded jdbc
driver and that the database was created in C:\apps\Ddlutils-test.
Otherwise you can give it the full path to the database [1]:


the URL would need to be tweaked for the client jdbc driver.[2]


[1] http://wiki.apache.org/db-derby/DatabaseNamesRelativeAbsolute
[2] http://db.apache.org/derby/docs/10.2/adminguide/cadminappsclient.html


Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! 
Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses



Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.

View raw message