How you install Oracle Application Express depends upon which HTTP server you Decide to use. There are three options
- 1: Oracle Application Express Listener
- 2: Embedded PL/SQL Gateway
- 3: Oracle HTTP Server
In all of these options Apex installation procedure is same and configuring Embedded PL/SQL Gateway is simpler. Embedded PL/SQL gateway provides the equivalent core features of Oracle HTTP Server and MOD_PLSQL.
In this article I’ll show how to install apex and configure the Embedded PL/SQL Gateway. In this case I've used
- Oracle Database 11gR2 (11.2.0)
- Oracle apex 4.2.5
- Toad 10.5
- Windows 7
Steps to install Oracle Apex
Login to database and create a table space (e.g.TS_APEX). Table space creating command is as below
CREATE TABLESPACE ts_apex DATAFILE 'C:\APP\ADMINISTRATOR\ORADATA\CANOPAS\TS_APEX01.DBF' SIZE 2048M AUTOEXTEND ON NEXT 100M MAXSIZE UNLIMITED LOGGING ONLINE PERMANENT EXTENT MANAGEMENT LOCAL AUTOALLOCATE BLOCKSIZE 8K FLASHBACK ON;
Unzip the apex folder. (Right click on apex_4.2.5.zip folder then choose extract here) you will find a folder named apex. Copy this folder anywhere on your hard drive you wish. In my case I’ve put it in C:\apex.
Open Command Prompt (cmd). Change your working directory to apex where you put the unzipped apex folder (in my case it is C:\apex). Below images showing the command
Now open SQL*Plus with nolog option by executing the command
C:\apex> sqlplus /nolog ENTERThen
SQL> conn sys as sysdba ENTER(To connect to database with sysdba privileges)
When password require enter sys user’s password. ENTER
Now you need to run apex installation file named apexins.sql. in command prompt enter the command like below
SQL> @apexins.sql ts_apex ts_apex temp /i/ ENTER
[ Here APEXINS.SQL is the apex main installation file. TS_APEX is the table space name which we creates at first step for apex user, apex files and temp is also a table space for apex temporary file. /i/ is a virtual drive for images. ]
It may take 30/40 minutes and may be disconnect from database. Remember whenever you disconnect from database every time you must follow the step (3, 4) to connect again.
When Oracle Application Express installs, it creates three new database accounts:
- • APEX_040100 - The account that owns the Oracle Application Express schema and metadata.
- • FLOWS_FILES - The account that owns the Oracle Application Express uploaded files.
- • APEX_PUBLIC_USER - The minimally privileged account used for Oracle
When installation is finished it shows message like flowing image
In a new installation of Oracle Application Express, you must change the password of the internal ADMIN account. To changes password connect to database again and run the flowing command
When prompted enter a password for the ADMIN account. It should be complex password like abcd#1234
Also you need to unlock APEX_PUBLIC_USER. To unlock account execute the following command
ALTER USER APEX_PUBLIC_USER ACCOUNT UNLOCK;
ALTER USER APEX_PUBLIC_USER IDENTIFIED BY new_password;
Configuring the embedded PL/SQL gateway
To Configuring the embedded PL/SQL gateway run apex_epg_config.sql passing the file system path to the base directory where the Oracle Application Express software was copied after unzipped as shown in the following example:
SQL> @apex_epg_config system_drive:\tempIn my case it is SQL> @apex_epg_config C:\
Then, you need to unlock the ANONYMOUS account.
ALTER USER ANONYMOUS ACCOUNT UNLOCK;
Enable Oracle XML DB HTTP server:
SQL> exec dbms_xdb.sethttpport(8080);
to make sure the port is set to 8080 run the following statement
select all DBMS_XDB.GETHTTPPORT() from dual
You could also check the following statement
select all t.status from dba_registry t where ( ( t.comp_id = 'APEX' )) expect VALID;
Unlock some users which are related to apex (anonymous, apex_030200, apex_040100, apex_public_user
How to Uninstall Oracle Application Express
Open Command Prompt. change your working directory to the apex folder where it was installed then connect to the database
sqlplus /nolog press enter
conn sys@xe as sysdbahere XE is database name.
After completed the process Remove the apex folder from the drive
Browse Apex from Your PC
Open a browser (firefox/Explorer etc). Write the URL: http://host:port/apex (eg: http://blackhorse:8080/apex) Your default workspace is- internal user name is- admin password is- admin user password which you changed at step 5
I hope it will help you to understand how to install and uninstall oracle application express
If you have any query\comment please leave it in comment box. I'll be very pleased to reply you. Thank you.