public synchronized void copyFileData(JDBCSequentialFile fileFrom,JDBCSequentialFile fileTo) throws SQLException {
  try {
    connection.setAutoCommit(false);
    copyFileRecord.setInt(1,fileFrom.getId());
    copyFileRecord.setInt(2,fileTo.getId());
    copyFileRecord.executeUpdate();
    connection.commit();
  }
 catch (  SQLException e) {
    connection.rollback();
    throw e;
  }
}

public synchronized void copyFileData ( JDBCSequentialFile fileFrom , JDBCSequentialFile fileTo ) throws SQLException { try { connection . setAutoCommit ( false ) ; copyFileRecord . setInt ( 1 , fileFrom . getId ( ) ) ; copyFileRecord . setInt ( 2 , fileTo . getId ( ) ) ; copyFileRecord . executeUpdate ( ) ; connection . commit ( ) ; } catch ( SQLException e ) { connection . rollback ( ) ; throw e ; } }
copy the data content of filefrom to fileto
