субота, 14. март 2009.

ORACLE APPLICATION EXPRESS 10g WITH COMPIERE ERP

Compiere ERP systems was installing on Oracle Application Express 10 g.
Theres 760 tables with all columns need for implement ERP systems (from orders, invoices, products or services with bill of materials for each products/services, with unit prices for every part from BOM-s, security settings and roles for manu users, storages (FIFO, LIFO) and production management life cycle.
First need install Oracle Application Express 10g and need create user COMPIERE with COMPIERE password
next need start COMPIERE2.SH formsetup compiere on pc


Fig 1> Oracle Application Express 10g and table M_BOM with records about products/services. This examples show relations in relation model.

Products need insert into compiere products. In examples here product is Measuerment transformer for higth voltage UH 9-15. This product have bill of material with 1000 elements.
EPA 10022378722 Porcelain insulator,
EPA 20938977866 Lid Steel sheet
EPA 89809008088 connectors hv x 2
EPA 80980789890 connectors lv x 10
.......................................................................
.......................................................................
EPA 89779987887 dilatable diaphragm


Fig 2> Products have basics elements, all elements have unit measure,unit prices and technical dates. So all products and basics elements need insert into Oracles tables (over compiere web javas UI) This forms looking like that>



Fig 3> Input forms for products (before that need set Organisations name, type division etc)

INSTALLATIONS

Додај сликуInstallation on Linux Ubuntu 8.04>
First step is downloads
Compiere 3.1 from sourceforge.net and Oracle Application Express 10g from www.oracle.com and JDK 1.6

Next need setting Environment as

nadrog@nadrog:~$ sudo gedit /etc/environment
and put this >

PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/lib/jvm:/home/nadrog:/home/nadrog/jdk1.6.0_11/bin:/home/nadrog/Adempiere/lib"
JAVA_HOME="/home/nadrog/jdk1.6.0_11"
JAVA="/home/nadrog/jdk1.6.0_11/bin/java"
CLASSPATH="/usr/lib/jvm:/home/nadrog"
JAVA_OPTS="-server -Xms128m -Xmx128m -Dprogram.name=run"
JRE_SRCROOT="/usr/lib/jvm/java-6-sun-1.6.0.07/bin/javaws"
ADEMPIERE_HOME="/home/nadrog/Adempiere"
JBOSS_HOME="/home/nadrog/Adempiere/jboss/lib"
COMPIERE_HOME="/home/nadrog/Compiere2"



Fig 4 > First step is to set ORACLE XE and JBOSS serves, user and password for compiere(and pass is compiere) and systems password form Oracle (during oracle 10 g installation step ). Compiere serves 1000 users by default, and ofer 100% security over internet. Oracle Application Express offer backup/restore/rman and have 4 gbytes spaces.

This ERP system is 100% free.

петак, 27. фебруар 2009.

validations with Apex

Validations with apex expres have step one-13 digits
next NUMERIC and last with condition above>

select :P4_JMBG from dual where
11-(
(
(7*(to_number(substr(:P2_JMBG,1,1))))+
(6*(to_number(substr(:P2_JMBG,2,1))))+
(5*(to_number(substr(:P2_JMBG,3,1))))+
(4*(to_number(substr(:P2_JMBG,4,1))))+
(3*(to_number(substr(:P2_JMBG,5,1))))+
(2*(to_number(substr(:P2_JMBG,6,1))))+
(7*(to_number(substr(:P2_JMBG,7,1))))+
(6*(to_number(substr(:P2_JMBG,8,1))))+
(5*(to_number(substr(:P2_JMBG,9,1))))+
(4*(to_number(substr(:P2_JMBG,10,1))))+
(3*(to_number(substr(:P2_JMBG,11,1))))+
(2*(to_number(substr(:P2_JMBG,12,1))))
)-
(FLOOR(((
(7*(to_number(substr(:P2_JMBG,1,1))))+
(6*(to_number(substr(:P2_JMBG,2,1))))+
(5*(to_number(substr(:P2_JMBG,3,1))))+
(4*(to_number(substr(:P2_JMBG,4,1))))+
(3*(to_number(substr(:P2_JMBG,5,1))))+
(2*(to_number(substr(:P2_JMBG,6,1))))+
(7*(to_number(substr(:P2_JMBG,7,1))))+
(6*(to_number(substr(:P2_JMBG,8,1))))+
(5*(to_number(substr(:P2_JMBG,9,1))))+
(4*(to_number(substr(:P2_JMBG,10,1))))+
(3*(to_number(substr(:P2_JMBG,11,1))))+
(2*(to_number(substr(:P2_JMBG,12,1))))
)
/11))*11))=to_number(substr(:P2_JMBG,13,1))
or
11-(
(
(7*(to_number(substr(:P2_JMBG,1,1))))+
(6*(to_number(substr(:P2_JMBG,2,1))))+
(5*(to_number(substr(:P2_JMBG,3,1))))+
(4*(to_number(substr(:P2_JMBG,4,1))))+
(3*(to_number(substr(:P2_JMBG,5,1))))+
(2*(to_number(substr(:P2_JMBG,6,1))))+
(7*(to_number(substr(:P2_JMBG,7,1))))+
(6*(to_number(substr(:P2_JMBG,8,1))))+
(5*(to_number(substr(:P2_JMBG,9,1))))+
(4*(to_number(substr(:P2_JMBG,10,1))))+
(3*(to_number(substr(:P2_JMBG,11,1))))+
(2*(to_number(substr(:P2_JMBG,12,1))))
)-
(FLOOR(((
(7*(to_number(substr(:P2_JMBG,1,1))))+
(6*(to_number(substr(:P2_JMBG,2,1))))+
(5*(to_number(substr(:P2_JMBG,3,1))))+
(4*(to_number(substr(:P2_JMBG,4,1))))+
(3*(to_number(substr(:P2_JMBG,5,1))))+
(2*(to_number(substr(:P2_JMBG,6,1))))+
(7*(to_number(substr(:P2_JMBG,7,1))))+
(6*(to_number(substr(:P2_JMBG,8,1))))+
(5*(to_number(substr(:P2_JMBG,9,1))))+
(4*(to_number(substr(:P2_JMBG,10,1))))+
(3*(to_number(substr(:P2_JMBG,11,1))))+
(2*(to_number(substr(:P2_JMBG,12,1))))
)
/11))*11))=11

references
http://en.wikipedia.org/wiki/Unique_Master_Citizen_Number
http://apex.oracle.com/pls/otn/f?p=39992:1

среда, 12. новембар 2008.

APEX on UBUNTU 8.04

I was installing APEX on Ubuntu 8.04 installing oracle xe 10.0.2.0.1.deb files typing from command terminall
sudo dpkg -i oracle-xe_10.2.0.1-1.0_i386.deb
after installing packages need type
-e
'/etc/init.d/oracle-xe configure'
type 8080
1521 and SYSTEM or SYS and password
and
'/etc/init.d/oracle-xe start'

as root user to configure database






APEX 2.0 on UBUNTU 8.04 with database space of 4 GbytesLINUX

петак, 31. октобар 2008.

asset management

Asset management have one main pages ASSET (with pk and fk referenced by asset char, asset state, asset history and more other assets)
Main pages are at>http://htmldb.oracle.com/pls/otn/f?p=38485:1:2547506111682738:::::

Fig 1: Main pages Asset Management. From left
side user can add new categories, states, conditions
performances and other attributess.
Додај слику

субота, 30. август 2008.

Apex and Ebs

I was installing web applications using apex 2/3.0.
Apex 3.1.0 have 20 templates which can implement user interfaces (forms) with insert/update
dates into tables (using trigger sequences mechanisms). At that moment I m waiting Apex 3.2 which will completed so nearly

This is themes have apex 3.1 installation and theres basic for Web Applications. Using AJAX developer can modify forms.

понедељак, 25. август 2008.

duplicate code, street_name and street_number

I was creating way how to solve problem with duplicate code, street_name and street_number.
so ther's duplicate code querys:

I have tableA(code, street_name,street_number, att1, att2) and theres duplicate code, street_name and street_numbers.
I was found duplicate code using:

select code from tableA where code in (select code from tableA group by code having count(*) >1)

but in meantime, code was changed and I have other code and old street_name and old street_number,
so tableA now have :
oldCODE,street_name, street_number and newCODE, street_name, street_number --- duplicate street_name and street_number!.
tableA have 7000 records.
Question is how found this duplicate street_name and street_number with this different code (old and new CODE)?


select STREET_NAME, STREET_NUMBER, max(ltrim(sys_connect_by_path(CODE,' - '),' -')) keep (dense_rank last order by length(sys_connect_by_path(CODE,' - ')))duplicate_code
from TABLEA

connect by prior CODE < CODE
and prior street_name =street_name
and prior street_number = street_number
group by STREET_NAME, STREET_NUMBER

having count(*)>1;


And ther's list of Street_Name, Street_Number, duplicate_CODE
100 of 15000 records!
So need update old code as 'NO ACTIVE'
or 'OLD VALUES'

петак, 22. август 2008.

HURIDOC apex information documentation system

Its reprogramming existing application writen on ms access
with that web (client server) on:
http://htmldb.oracle.com/pls/otn/f?p=20604:4:3119063912909518:::::



When user login into this documentation system, can see options from main menu
Users can change, edit or only read informations according rolles