Patches [1700186] - Remove more references to derby/fyracle

https://sourceforge.net/tracker/?func=detail&atid=879334&aid=1700186&group_id=176962
This commit is contained in:
trifonnt 2010-04-16 21:29:26 +00:00
parent 1125ff510c
commit 57705cb22b
19 changed files with 25 additions and 8720 deletions

View File

@ -10,13 +10,13 @@ ADEMPIERE_JAVA_TYPE=sun
#Java runtime options
ADEMPIERE_JAVA_OPTIONS=-Xms64M -Xmx512M
#Type of database, postgresql|oracle|oracleXE|fyracle
#Type of database, postgresql|oracle|oracleXE
ADEMPIERE_DB_TYPE=postgresql
#Path to database specific sql scripts: postgresql|oracle|oracleXE|fyracle
#Path to database specific sql scripts: postgresql|oracle|oracleXE
ADEMPIERE_DB_PATH=postgresql
#Database server host name
ADEMPIERE_DB_SERVER=localhost
#Database port, oracle[1512], postgresql[5432], fyracle[3500]
#Database port, oracle[1512], postgresql[5432]
ADEMPIERE_DB_PORT=5432
#Database name
ADEMPIERE_DB_NAME=adempiere

View File

@ -20,7 +20,7 @@ goto START
@Echo =======================================
@Echo Starting Setup Dialog ...
@Echo =======================================
@SET CP=lib\CInstall.jar;lib\Adempiere.jar;lib\CCTools.jar;lib\oracle.jar;lib\fyracle.jar;lib\derby.jar;lib\jboss.jar;lib\postgresql.jar;
@SET CP=lib\CInstall.jar;lib\Adempiere.jar;lib\CCTools.jar;lib\oracle.jar;lib\jboss.jar;lib\postgresql.jar;
@Rem Trace Level Parameter, e.g. SET ARGS=ALL
@SET ARGS=CONFIG

View File

@ -18,7 +18,7 @@ fi
echo ===================================
echo Setup Dialog
echo ===================================
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/derby.jar:lib/fyracle.jar:lib/jboss.jar:lib/postgresql.jar:
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/jboss.jar:lib/postgresql.jar:
# Trace Level Parameter, e.g. ARGS=ALL
ARGS=CONFIG

View File

@ -20,7 +20,7 @@ goto START
@Echo =======================================
@Echo Starting Setup ...
@Echo =======================================
@SET CP=lib\CInstall.jar;lib\Adempiere.jar;lib\CCTools.jar;lib\oracle.jar;lib\fyracle.jar;lib\derby.jar;lib\jboss.jar;lib\postgresql.jar;
@SET CP=lib\CInstall.jar;lib\Adempiere.jar;lib\CCTools.jar;lib\oracle.jar;lib\jboss.jar;lib\postgresql.jar;
@Rem Trace Level Parameter, e.g. SET ARGS=ALL
@SET ARGS=CONFIG

View File

@ -18,7 +18,7 @@ fi
echo ===================================
echo Starting Setup ...
echo ===================================
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/derby.jar:lib/fyracle.jar:lib/jboss.jar:lib/postgresql.jar:
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/jboss.jar:lib/postgresql.jar:
# Trace Level Parameter, e.g. ARGS=ALL
ARGS=CONFIG

View File

@ -17,5 +17,5 @@ fi
#echo ===================================
#echo Update Adempiere Server Environment
#echo ===================================
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/derby.jar:lib/fyracle.jar:lib/jboss.jar:lib/postgresql.jar:
CP=lib/CInstall.jar:lib/Adempiere.jar:lib/CCTools.jar:lib/oracle.jar:lib/jboss.jar:lib/postgresql.jar:
$JAVA -classpath $CP -DADEMPIERE_HOME=$ADEMPIERE_HOME -Dant.home="." org.apache.tools.ant.launch.Launcher update

11
nbproject/.project Normal file
View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>nbproject</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
</buildSpec>
<natures>
</natures>
</projectDescription>

View File

@ -211,7 +211,7 @@
<package-root>webCM/src</package-root>
<package-root>webStore/src</package-root>
<package-root>migration</package-root>
<classpath mode="compile">lib/Adempiere.jar:lib/CCTools.jar:lib/CompiereJasperReqs.jar:lib/CSTools.jar:lib/customization.jar:lib/db2.jar:lib/derby.jar:lib/jboss.jar:lib/oracle.jar:lib/patches.jar:lib/postgresql.jar</classpath>
<classpath mode="compile">lib/Adempiere.jar:lib/CCTools.jar:lib/CompiereJasperReqs.jar:lib/CSTools.jar:lib/customization.jar:lib/db2.jar:lib/jboss.jar:lib/oracle.jar:lib/patches.jar:lib/postgresql.jar</classpath>
<source-level>1.5</source-level>
</compilation-unit>
</java-data>

View File

@ -1,10 +0,0 @@
@if (%ADEMPIERE_HOME%) == () (CALL ..\myEnvironment.bat Server) else (CALL %ADEMPIERE_HOME%\utils\myEnvironment.bat Server)
@Title Create Oracle SQLJ - %ADEMPIERE_HOME% (%ADEMPIERE_DB_NAME%)
@Rem
@Rem Author + Copyright 1999-2005 Jorg Janke
@Rem $Id: RUN_sqlj.bat,v 1.1 2005/04/27 05:21:46 jjanke Exp $
@Rem
call create %ADEMPIERE_DB_USER%/%ADEMPIERE_DB_PASSWORD%
@pause

View File

@ -1,10 +0,0 @@
# Author + Copyright 1999-2005 Jorg Janke
# $Id: RUN_sqlj.sh,v 1.1 2005/05/31 07:28:21 jjanke Exp $
if [ $ADEMPIERE_HOME ]; then
cd $ADEMPIERE_HOME/utils
fi
. ./myEnvironment.sh Server
echo Create Oracle SQLJ - $ADEMPIERE_HOME \($ADEMPIERE_DB_NAME\)
sh $ADEMPIERE_DB_PATH/create.sh $ADEMPIERE_DB_USER/$ADEMPIERE_DB_PASSWORD

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,14 +0,0 @@
@Rem Create Derby SQLJ
@Rem
@Rem
@Rem runDefault first
@Rem
@Echo on
@if !"%SQLJPATH%"==! call setDefault.bat
@Echo Load Derby SQLJ and functions...
@REM SET CLASSPATH=
@java -Dij.driver=org.apache.derby.jdbc.ClientDriver -Dij.connection.Adempiere=jdbc:derby:%Derby_path%\Adempiere;create=true -Dij.user=%IJ_USER% -Dij.password=%IJ_PASSWORD% org.apache.derby.tools.ij < %SQLJPATH%\derby\createSQLJ.sql
pause

View File

@ -1,15 +0,0 @@
# Create Oracle SQLJ
# Author + Copyright 1999-2005 Jorg Janke
# $Id: create.sh,v 1.3 2005/06/28 18:55:38 jjanke Exp $
#
# Parameter: <adempiereDBuser>/<adempiereDBpassword>
# unset CLASSPATH=
echo .
echo Load Oracle SQLJ ...
loadjava -user $1@$ADEMPIERE_DB_NAME -verbose -force -resolve $ADEMPIERE_HOME/lib/sqlj.jar
echo .
echo Create Oracle Functions ...
sqlplus $1@$ADEMPIERE_DB_NAME @$ADEMPIERE_HOME/utils/oracle/createSQLJ.sql

View File

@ -1,308 +0,0 @@
--
-- Create SQL Java Functions (Derby)
--
-- Author + Copyright 1999-2005 Jorg Janke
-- 09-28-2006 Jinglun Zhang modified from sqlj/oracle, ignore drop errors
--
-- load sqlj.jar to Derby
Call SQLJ.REMOVE_JAR ('adempiere_sqlj',0);
Call SQLJ.INSTALL_JAR ('c:\adempiere\adempiere-all2\sqlj\sqlj.jar', 'adempiere_sqlj', 0);
call SYSCS_UTIL.SYSCS_SET_DATABASE_PROPERTY('derby.database.classpath','ADEMPIERE.adempiere_sqlj');
-- drop/create functions
DROP FUNCTION adempiereVersion;
CREATE FUNCTION adempiereVersion()
RETURNS VARCHAR(255)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getVersion';
DROP FUNCTION adempiereProperties;
CREATE FUNCTION adempiereProperties()
RETURNS VARCHAR(1022)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getProperties';
DROP FUNCTION adempiereProperty;
CREATE FUNCTION adempiereProperty(p_key VARCHAR(255))
RETURNS VARCHAR(1022)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getProperty';
-- Product --
DROP FUNCTION productAttribute;
CREATE FUNCTION productAttribute (M_AttributeSetInstance_ID int)
RETURNS VARCHAR(255)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.attributeName';
DROP FUNCTION bomPriceLimit;
CREATE FUNCTION bomPriceLimit (M_Product_ID int, M_PriceList_Version_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomPriceLimit';
DROP FUNCTION bomPriceList;
CREATE FUNCTION bomPriceList (M_Product_ID int, M_PriceList_Version_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomPriceList';
DROP FUNCTION bomPriceStd;
CREATE FUNCTION bomPriceStd (M_Product_ID int, M_PriceList_Version_ID int)
RETURNS Decimal(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomPriceStd';
DROP FUNCTION bomQtyAvailable;
CREATE FUNCTION bomQtyAvailable (M_Product_ID int, M_Warehouse_ID int,
M_Locator_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomQtyAvailable';
DROP FUNCTION bomQtyOnHand;
CREATE FUNCTION bomQtyOnHand (M_Product_ID int, M_Warehouse_ID int,
M_Locator_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomQtyOnHand';
DROP FUNCTION bomQtyOrdered;
CREATE FUNCTION bomQtyOrdered (M_Product_ID int, M_Warehouse_ID int,
M_Locator_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomQtyOrdered';
DROP FUNCTION bomQtyReserved;
CREATE FUNCTION bomQtyReserved (M_Product_ID int, M_Warehouse_ID int,
M_Locator_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Product.bomQtyReserved';
-- Currency --
DROP FUNCTION currencyBase;
CREATE FUNCTION currencyBase (Amount DECIMAL(31,5), C_CurrencyFrom_ID int,
ConversionDate TIMESTAMP, AD_Client_ID int, AD_Org_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Currency.base';
DROP FUNCTION currencyConvert;
--CREATE FUNCTION currencyConvert (Amount DOUBLE, C_CurrencyFrom_ID int,
-- C_CurrencyTo_ID int,
-- ConversionDate TIMESTAMP, C_ConversionType_ID int, AD_Client_ID int, AD_Org_ID int)
-- RETURNS DOUBLE
CREATE FUNCTION currencyConvert (Amount DECIMAL(31,5), C_CurrencyFrom_ID int,
C_CurrencyTo_ID int,
ConversionDate TIMESTAMP, C_ConversionType_ID int, AD_Client_ID int, AD_Org_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Currency.convert';
DROP FUNCTION currencyRate;
CREATE FUNCTION currencyRate (C_CurrencyFrom_ID int, C_CurrencyTo_ID int,
ConversionDate TIMESTAMP, C_ConversionType_ID int, AD_Client_ID int, AD_Org_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Currency.rate';
DROP FUNCTION currencyRound;
CREATE FUNCTION currencyRound (Amt DECIMAL(31,5), C_CurrencyTo_ID int, IsCosting VARCHAR(2))
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Currency.round';
-- BPartner --
DROP FUNCTION bpartnerRemitLocation;
CREATE FUNCTION bpartnerRemitLocation (p_C_BPartner_ID int)
RETURNS int
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.BPartner.remitLocation';
-- Invoice --
DROP FUNCTION invoiceOpen;
CREATE FUNCTION invoiceOpen (p_C_Invoice_ID int, p_C_InvoicePaySchedule_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Invoice.open';
DROP FUNCTION invoicePaid;
CREATE FUNCTION invoicePaid (p_C_Invoice_ID int, p_C_Currency_ID int,
p_MultiplierAP int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Invoice.paid';
DROP FUNCTION invoiceDiscount;
CREATE FUNCTION invoiceDiscount (p_C_Invoice_ID int, p_PayDate TIMESTAMP,
p_C_InvoicePaySchedule_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Invoice.discount';
-- Payment Term --
DROP FUNCTION paymentTermDueDays;
CREATE FUNCTION paymentTermDueDays (p_C_PaymentTerm_ID int, p_DocDate TIMESTAMP,
p_PayDate TIMESTAMP)
RETURNS int
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.PaymentTerm.dueDays';
DROP FUNCTION paymentTermDiscount;
CREATE FUNCTION paymentTermDiscount (p_Amount DECIMAL(31,5), p_C_Currency_ID int,
p_C_PaymentTerm_ID int, p_DocDate TIMESTAMP, p_PayDate TIMESTAMP)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.PaymentTerm.discount';
DROP FUNCTION paymentTermDueDate;
CREATE FUNCTION paymentTermDueDate (p_C_PaymentTerm_ID int, p_DocDate TIMESTAMP)
RETURNS TIMESTAMP
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.PaymentTerm.dueDate';
-- Payment --
DROP FUNCTION paymentAllocated;
CREATE FUNCTION paymentAllocated (p_C_Payment_ID int, p_C_Currency_ID int)
RETURNS DECIMAL(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Payment.allocated';
DROP FUNCTION paymentAvailable;
CREATE FUNCTION paymentAvailable (p_C_Payment_ID int)
RETURNS Decimal(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Payment.available';
-- Account --
DROP FUNCTION acctBalance;
CREATE FUNCTION acctBalance (p_Account_ID int, p_AmtDr Decimal(31,5), p_AmtCr Decimal(31,5))
RETURNS Decimal(31,5)
PARAMETER STYLE JAVA LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Account.balance';
-- General --
--BEGIN
-- dbms_java.grant_permission('ADEMPIERE','SYS:java.util.PropertyPermission', '*', 'read,write');
--END;
-- Get Character at Position
DROP FUNCTION charAt;
CREATE FUNCTION charAt
(
p_string VARCHAR(2046),
p_pos int
)
RETURNS CHAR
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.charAt';
-- GetDate
DROP FUNCTION getdate;
CREATE FUNCTION getdate()
RETURNS TIMESTAMP
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getDate';
-- First Of DD/DY/MM/Q
DROP FUNCTION firstOf;
CREATE FUNCTION firstOf
(
p_date TIMESTAMP,
p_datePart VARCHAR(26)
)
RETURNS TIMESTAMP
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.firstOf';
-- Add Number of Days
DROP FUNCTION addDays;
CREATE FUNCTION addDays
(
p_date TIMESTAMP,
p_days int
)
RETURNS TIMESTAMP
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.addDays';
-- Difference in Days
DROP FUNCTION getDaysBetween;
CREATE FUNCTION getDaysBetween
(
p_date1 TIMESTAMP,
p_date2 TIMESTAMP
)
RETURNS int
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getDaysBetween';
-- Truncate Date
DROP FUNCTION trunc;
CREATE FUNCTION trunc
(
p_dateTime TIMESTAMP
)
RETURNS TIMESTAMP
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.trunc';
-- convert number to chars
DROP FUNCTION getChars;
CREATE FUNCTION getChars
(
p_number DECIMAL(31,5)
)
RETURNS VARCHAR(38)
PARAMETER STYLE JAVA NO SQL LANGUAGE JAVA
EXTERNAL NAME 'org.compiere.sqlj.Adempiere.getChars';
SELECT adempiereVersion(), adempiereProperty('java.vendor'),
getdate() FROM sysibm.sysdummy1;

View File

@ -1,4 +0,0 @@
Rem Set default for Derby
set SQLJPATH=c:\adempiere\adempiere-all2\sqlj
set derby_path=c:\adempiere\adempiere-all2\derby

File diff suppressed because it is too large Load Diff

View File

@ -9,6 +9,6 @@
@Echo =======================================
@Echo Sign Database Build
@Echo =======================================
@SET CP=%ADEMPIERE_HOME%\lib\CInstall.jar;%ADEMPIERE_HOME%\lib\Adempiere.jar;%ADEMPIERE_HOME%\lib\CCTools.jar;%ADEMPIERE_HOME%\lib\oracle.jar;%ADEMPIERE_HOME%\lib\fyracle.jar;%ADEMPIERE_HOME%\lib\derby.jar;%ADEMPIERE_HOME%\lib\jboss.jar;%ADEMPIERE_HOME%\lib\postgresql.jar;
@SET CP=%ADEMPIERE_HOME%\lib\CInstall.jar;%ADEMPIERE_HOME%\lib\Adempiere.jar;%ADEMPIERE_HOME%\lib\CCTools.jar;%ADEMPIERE_HOME%\lib\oracle.jar;%ADEMPIERE_HOME%\lib\jboss.jar;%ADEMPIERE_HOME%\lib\postgresql.jar;
@"%JAVA%" -classpath %CP% -DADEMPIERE_HOME=%ADEMPIERE_HOME% org.adempiere.process.SignDatabaseBuild

View File

@ -13,6 +13,6 @@ JAVA=$JAVA_HOME/bin/java
echo ===================================
echo Sign Database Build
echo ===================================
CP=$ADEMPIERE_HOME/lib/CInstall.jar:$ADEMPIERE_HOME/lib/Adempiere.jar:$ADEMPIERE_HOME/lib/CCTools.jar:$ADEMPIERE_HOME/lib/oracle.jar:$ADEMPIERE_HOME/lib/derby.jar:$ADEMPIERE_HOME/lib/fyracle.jar:$ADEMPIERE_HOME/lib/jboss.jar:$ADEMPIERE_HOME/lib/postgresql.jar:
CP=$ADEMPIERE_HOME/lib/CInstall.jar:$ADEMPIERE_HOME/lib/Adempiere.jar:$ADEMPIERE_HOME/lib/CCTools.jar:$ADEMPIERE_HOME/lib/oracle.jar:$ADEMPIERE_HOME/lib/jboss.jar:$ADEMPIERE_HOME/lib/postgresql.jar:
$JAVA -classpath $CP -DADEMPIERE_HOME=$ADEMPIERE_HOME org.adempiere.process.SignDatabaseBuild