1.Compiereの最新プログラムを既存のCompiereのフォルダに上書き保存
Compiereの最新プログラムのフォルダを既存のCompiereのフォルダに上書き保存します。
その時に、ログイン用のプロパティファイルのファイル名が最新プログラムと同じ場合には、上書きされないように注意します。
2.Run_Setup.batを実行
Compiere2フォルダにの直下にある、Run_Setup.batを実行します。
Compiereのサーバー設定を行い、一度テストをしたから、その設定を保存します。ここでログイン用のプロパティファイルが、C:\Documents and Settings\ユーザー名の直下に、Compiere.propertiesという名称で作成されます。
補足:データを復元させる場合(Oracle)
D:\Compiere2\utils\oracleの直下にある、DBRestore.batのファイルを下記のように編集します。
FROMUSER=(%2)の所をFROMUSER=(compiere)にします。
--------------------以下全文----------------------------
@Echo Compiere Database Restore $Revision: 1.3 $
@Rem $Id: DBRestore.bat,v 1.3 2009/02/16 07:28:07 jiaoyu Exp $
@Echo Restoring Compiere DB from %COMPIERE_HOME%\data\ExpDat.dmp
@if (%COMPIERE_HOME%) == () goto environment
@if (%COMPIERE_DB_NAME%) == () goto environment
@Rem Must have parameter: systemAccount compiereID CompierePwd
@if (%1) == () goto usage
@if (%2) == () goto usage
@if (%3) == () goto usage
@echo -------------------------------------
@echo Re-Create DB user
@echo -------------------------------------
@sqlplus %1@%COMPIERE_DB_NAME% @%COMPIERE_HOME%\utils\%COMPIERE_DB_PATH%\CreateUser.sql %2 %3
@echo -------------------------------------
@echo Import ExpDat
@echo -------------------------------------
@imp %1@%COMPIERE_DB_NAME% FILE=%COMPIERE_HOME%\data\ExpDat.dmp FROMUSER=(compiere) TOUSER=%2 STATISTICS=RECALCULATE
@echo -------------------------------------
@if (%COMPIERE_DB_TYPE%) == (%COMPIERE_DB_PATH%) echo Create SQLJ
@echo -------------------------------------
@if (%COMPIERE_DB_TYPE%) == (%COMPIERE_DB_PATH%) call %COMPIERE_HOME%\Utils\%COMPIERE_DB_PATH%\create %COMPIERE_DB_USER%/%COMPIERE_DB_PASSWORD%
@echo -------------------------------------
@echo Check System
@echo Import may show some warnings. This is OK as long as the following does not show errors
@echo -------------------------------------
@sqlplus %2/%3@%COMPIERE_DB_NAME% @%COMPIERE_HOME%\utils\%COMPIERE_DB_PATH%\AfterImport.sql
@goto end
:environment
@Echo Please make sure that the enviroment variables are set correctly:
@Echo COMPIERE_HOME e.g. D:\Compiere2
@Echo COMPIERE_DB_NAME e.g. dev1.compiere.org
:usage
@echo Usage: %0% <systemAccount> <CompiereID> <CompierePwd>
@echo Example: %0% system/manager compiere compiere
:end
最後に、D:\Compiere2\utilsの直下にある、Run_DBRestore.batを実行します。