If your table already exist, I would modify the hibernate3 plugin so it doesn't run except when you explicitly run it (e.g. in a profile).
Matt On Wed, Feb 17, 2010 at 4:34 AM, patrick24 <patrick.hartk...@zueblin.de> wrote: > > I checked out a new AppFuse project from the lates snapshot: > AppFuese 2.1.0-M2-Snapshot / Single-Mode / JSF / Full Source > > That worked out fine. Now I want to preserve the database contents and get > an error when I change in the pom.xml: > > <dbunit.operation.type>CLEAN_INSERT</dbunit.operation.type> > to > <dbunit.operation.type>UPDATE</dbunit.operation.type> > and (at hbm2ddl) > <drop>true</drop> > to > <drop>false</drop> > > > Running mvn clean / mvn jetty:run / mvn jetty:run-war generates the > following error: > > ERROR [main] SchemaExport.create(348) | Unsuccessful: create table app_user > ... > ERROR [main] SchemaExport.create(348) | Unsuccessful: create table app_user > ... and so on for all tables > [WARNING] 9 errors occurred while performing <hbm2ddl>. > [ERROR] Error #1: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: > Table 'app_user' already exists > ... and so on for all tables > [INFO] Error executing database operation: UPDATE > Embedded error: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: > You have an error in your SQL syntax; check the manual that corresponds to > your MySQL server version for the right syntax to use near 'where user_id = > -1 and role_id = -2' at line 1 > > I remember this worked fine for recent AppFuse projects. > Is there anything wrong? > A dbunit bug? > > Thanks for helping > Patrick > > > > > -- > View this message in context: > http://n4.nabble.com/Error-preserving-database-using-dbunit-operation-type-UPDATE-dbunit-operation-type-tp1558529p1558529.html > Sent from the AppFuse - User mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net > For additional commands, e-mail: users-h...@appfuse.dev.java.net > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net For additional commands, e-mail: users-h...@appfuse.dev.java.net