db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Luis Angel Fernandez Fernandez" <laff...@gmail.com>
Subject Re: how to copy a derby db?
Date Sun, 16 Dec 2007 08:51:01 GMT
2007/12/16, Amir Michail <amichail@gmail.com>:
> Hi,

  Hi

> Can I copy a db while it is being used or could that lead to a corrupted copy?

  I can be wrong, but I think you could use something like...

      String str = "CALL SYSCS_UTIL.SYSCS_BACKUP_DATABASE(?)";
      CallableStatement cs =  ApplyDBChanges.getConn().prepareCall(str);
      cs.setString(1, fileName);
      cs.execute();

  to make the copy.

  But I think this has to be done from the same connection, so if you
meant to make a copy from outside the program using the database what
I said above will not work (I think).

  Bye!

Mime
View raw message