Wikia

How To Wiki

Oracle Applications HOWTO: copy personalization

1,794pages on
this wiki
Talk0

Go to Michael Dvorkin's user page

Prerequisites Edit

E-Business Suite 11.5.10


Steps to copy personalization Edit

1. Find the name of the page having required personalization

  Click the "about this page" link at the bottom of the page
  Copy the full page name (including path)

2. For every page - find a list of customizations

  sqlplus apps/<apps password>
  set lines 300
  set serveroutput on
  exec dbms_output.enable(1000000);
  exec jdr_utils.listCustomizations('<full page name>');
  exit;

3. Download customizations found in the previous step

  The following should be done for every customization:
  java oracle.jrad.tools.xml.exporter.XMLExporter "<customization name>" -username "apps" -password <apps password> -dbconnection "(description=(address_list=(address=(community=tcp.world)(protocol=tcp)(host=<host> port=<port>)))(connect_data=(sid=<ORACLE_SID>)))" -rootdir .
  <host> - source database host
  <port> - source database port
  <ORACLE_SID> - source database SID
  This will create a file <customization name>.xml in current directory

4. Upload customizations to other environment

  The following should be done for every customization downloaded in previous step:
  java oracle.jrad.tools.xml.importer.XMLImporter <customization name>.xml  -username "apps" -password <apps password> -dbconnection "(description=(address_list=(address=(community=tcp.world)(protocol=tcp)(host=<host>)(port=<port>)))(connect_data=(sid=<ORACLE_SID>)))" -rootdir . -rootPackage <customization name>
  <host> - target database host
  <port> - target database port
  <ORACLE_SID> - target database SID
   

Sample script Edit

Note that this script is for testing purposes only and cannot be used in production.

START OF THE SCRIPT
#!/bin/ksh
# ---------------------------------------------------------------------------------------
# File page_names.txt must exist in current directory and must have a list of page names having required personalizations
# (See step 1)
# ---------------------------------------------------------------------------------------
export INFILE="page_names.txt"
# ---------------------------------------------------------------------------------------

export TMPINFILE=/tmp/${INFILE}.tmp

# ---------------------------------------------------------------------------------------
# The following section contains definitions that should be changed according to specific environment settings
# ---------------------------------------------------------------------------------------
export FROM_APPSPWD=apps
export FROM_SID=DEV
export FROM_HOST=`hostname`
export FROM_PORT=1521

export TO_APPSPWD=apps
export TO_SID=TST
export TO_HOST=`hostname`
export TO_PORT=1531
# ---------------------------------------------------------------------------------------

export ROOT_DIR=.

for name in `cat ${INFILE} | grep -v ^$`
do

sqlplus apps/${FROM_APPSPWD} << XXX
set lines 300
set serveroutput on
exec dbms_output.enable(1000000);
spool $TMPINFILE
exec jdr_utils.listCustomizations('$name');
spool off
exit;

XXX

for new_name in `cat $TMPINFILE | grep -v ^$ | grep '^/'`
do


echo "Copying $new_name"


java oracle.jrad.tools.xml.exporter.XMLExporter "$new_name" -username "apps" -password $FROM_APPSPWD -dbconnection "(description=(address_list=(address=(community=tcp.world)(protocol=tcp)(host=${FROM_HOST})(port=${FROM_PORT})))(connect_data=(sid=${FROM_SID})))" -rootdir $ROOT_DIR


java oracle.jrad.tools.xml.importer.XMLImporter "${ROOT_DIR}/${new_name}.xml" -username "apps" -password $TO_APPSPWD -dbconnection "(description=(address_list=(address=(community=tcp.world)(protocol=tcp)(host=${TO_HOST})(port=${TO_PORT})))(connect_data=(sid=${TO_SID})))" -rootdir $ROOT_DIR -rootPackage "$name"


done


done

exit 0
END OF THE SCRIPT

Known Issues Edit

1. Symptom : Cannot execute java

  Cause   : java executable is not in the PATH
  Solution: Add a path to java to the PATH variable, for example:
            export PATH=${PATH}:/opt/java1.3/bin

Go to Michael Dvorkin's user page

Around Wikia's network

Random Wiki