5 Replies Latest reply on Jun 10, 2005 3:35 AM by jim168

    Changing database structure

    ebu

      Hi.
      Definitely somebody already got the experience of changing database with data which is used by JBoss for CMP. Is there some pitfalls in using special update script generation tools such as DB SynchroComp (http://www.e-dule.com/) ? Or maybe there are better approaches?

      thanx, eugen.

        • 1. Re: Changing database structure
          triathlon98

          Maybe you could check out the alter-table setting in JBoss. See the wiki pages about the CMP engine.

          Joachim

          • 2. Re: Changing database structure
            ebu

            Have you used this option in production system with important data? Everything was smooth? I saw couple of times that it tried to update table in a way that caused SQL Exception... so i would still afraid to entrust this process to JBoss :). Besides this while using script you can easily create backup ...

            • 3. Re: Changing database structure
              triathlon98

              Using it all the time, on production databases, use firebird as database server. Works like a dream.

              Firebird will throw an exception if the database has other users. Apart from that, no problems so far (and I add fields quite often).

              Joachim

              • 4. Re: Changing database structure
                ebu

                Ok, thank you very mcuh.

                • 5. Re: Changing database structure

                  OS: Windows 2000
                  JBoss:4.0.2
                  EJB3.0:Preview 5
                  hibernate.hbm2ddl.auto=update

                  no matter alter-table is set or not:
                  when there is a property added in entity bean, there is a field added. :)
                  when there is a property deleted in entity bean, nothing changed in db table. :(

                  Is that a issue not implemented yet and called EJBTHREE-176?