I tested the same with the latest version h2-1.3.154.
Now a different error occurs:
2011-04-26 23:55:34,953 [AWT-EventQueue-0] ERROR database.db.Database:
org.h2.jdbc.JdbcSQLException: Kann "MOVIE" nicht löschen weil
"DUPLICATETITLE" davon abhängt
Cannot drop "MOVIE" because "DUPLICATETITLE" depends on it; SQL
statement:
The reason is obviously if you look into generated SQL:
DROP TABLE IF EXISTS PUBLIC.MOVIE;
....
DROP TABLE IF EXISTS PUBLIC.AUDIO;
....
DROP VIEW IF EXISTS PUBLIC.DUPLICATETITLE;
...
DROP TABLE IF EXISTS PUBLIC.MEDIUM;
The order of the generated drop statements is wrong. As you can see
above the view DUPLICATETITLE depends on the tables MOVIE; AUDIO and
MEDIUM and should be therefore dropped before these tables.
If i correct the order manually and do a restore via
RunScript.main("-url", getDatabaseURL(database), "-script",
backUpFile, "-user", null , "-password", null);
everything works fine.
So, is there a way to report this error as bug ?
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/h2-database?hl=en.