Wednesday, January 1, 2014

FNDLOAD commands to upload and download setups in R12 Oracle apps instance

FNDLOAD utility is provided by oracle to migrate setups from one instance to another. This is capable of migrating most of the common setups in an Oracle apps instance. This covers most of the setups stored in FND schema. Steps is, perform the setups manually in the source instance (Eg: Development or test instance) and download the ldt file. This is a regular text file – not any executable or so. We can view the file and validate/correct the data if required. Then we can FTP this file in ASCII mode to the target instance and then upload this ldt file with a valid command. Few of the commonly used components migrated using FNDLOAD utility are as follows (detailed list is mentioned towards the end of the post):

1.       Concurrent Programs
2.       Request Groups
3.       Request Sets
4.       Menus
5.       Responsibilities
6.       Form Registration
7.       Function
8.       Valueset
9.       Profiles
10.   Descriptive Flex Fields
11.   Key Flex Fields
12.   Messages
13.   AK Region and Attributes
14.   JTF Meta data
15.   Form Personalization
16.   Printer Styles
17.   User Definitions
18.   Alert
19.   XMLP Template definitions
20.   Attachments
21.   FND Dictionary
22.   HELP Configuration
23.   Document sequences
24.   Concurrent Manager Schedules

Concept:
FNDLOAD utility is located in $FND_TOP/bin folder. Oracle has provided configuration files for downloading each of these setups. These configuration files end with extension .lct. These are located in $FND_TOP/patch/115/import/ folder.

Syntax:
FNDLOAD $APPSLOGIN 0 Y <Mode> <lct file> <ldt data file> <Option> <Parameters>

$APPSLOGIN environment variable stores the apps username and password. If not replace this with apps/<pwd>@SID
Mode is either DOWNLOAD or UPLOAD
Lct file is the full path to the configuration file
Ldt file is the data file that will be downloaded or uploaded
Option is the setup that we want to download
Parameters if we want to certain part of the setup (may not be applicable for all)


Few notes:

1.       If the target instance already has a value and you are trying to delete it, the FNDLOAD may not help, it only updates or inserts data, not delete. Those might have to be done manually
2.       As said, it can migrate FND setups, for those of financials or HRMS setups migration we might have to use Oracle iSetup
3.       Be careful while downloading the values, might move some of the dev/test instance values to PROD by mistake!
4.       I recommend downloading the ldts from PROD, load to dev, then make required changes on top to ensure valid changes are present
5.       While migrating request group etc, I recommend migrating only the unit that was added rather than full request group. This will avoid moving redundant data if someone had added other programs as well to the request group in the dev/test environment
6.       Form personalizations – try to download all personalizations. It generally overwrites personalizations in the form

Example commands:

1.       Concurrent Programs
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afcpprog.lct XX_CP.ldt PROGRAM APPLICATION_SHORT_NAME="APP_SHORT_NAME" CONCURRENT_PROGRAM_NAME="CP_SHORT_NAME"

2.       Request Groups
a.       Complete Request Group
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct XX_MY_REPORT_GROUP_NAME.ldt REQUEST_GROUP REQUEST_GROUP_NAME="XX_MY_REPORT_GROUP_NAME" APPLICATION_SHORT_NAME="APP_SHORT_NAME"

b.      One unit in the Request Group
FNDLOAD $APPSLOGIN  0 Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct XXReqgrp_XX_MY_REPORT.ldt REQUEST_GROUP REQUEST_GROUP_NAME="XX_MY_REPORT_GROUP_NAME" UNIT_APP=APP_SHORT_NAME UNIT_NAME= XX_MY_REPORT

3.       Request Sets
a.       Entire Request Set
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct XX_ REPORTS_SET.ldt REQ_SET REQUEST_SET_NAME="XX_REPORTS_SET"

b.      Request Set Stage
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct XX_ REPORTS_SET.ldt  REQ_SET_LINKS REQUEST_SET_NAME="XX_REPORTS_SET" STAGE_NAME=”XX_STAGE_NAME”

c.       Program in a Request set
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct XX_ REPORTS_SET.ldt  REQ_SET_LINKS REQUEST_SET_NAME="XX_REPORTS_SET" STAGE_NAME=”XX_STAGE_NAME” SEQUENCE=”XX_SEQUENCE"

4.       Menus
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct XX_MENU.ldt MENU MENU_NAME="XX_MENU"

5.       Responsibilities
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afscursp.lct XX_RESPY.ldt FND_RESPONSIBILITY RESP_KEY="XX_RESPY"

6.       Form Registration
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct XX_FORM.ldt FORM FORM_NAME="XX_FORM"

7.       Menu Function
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct XX_FUNCTION.ldt MENU PARENT_MENU_NAME=”XX_PARENT_MENU” FUNCTION_NAME=”XX_FUNCTION_NAME”

8.       Valueset
$FND_TOP/bin/FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct XX_VS.ldt VALUE_SET FLEX_VALUE_SET_NAME=XX_VS

9.       Profile Options
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afscprof.lct XX_PROF.ldt PROFILE PROFILE_NAME="XX_PROF" APPLICATION_SHORT_NAME="FND"

10.   Descriptive Flex Fields
a.       Full DFF
$FND_TOP/bin/FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct XX_DFF.ldt DESC_FLEX APPLICATION_SHORT_NAME=PO DESCRIPTIVE_FLEXFIELD_NAME='PO_REQUISITION_HEADERS'

b.      One context in a DFF
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct <LDT FileName>.ldt DESC_FLEX APPLICATION_SHORT_NAME='FND' DESCRIPTIVE_FLEXFIELD_NAME='FND_FLEX_VALUES'  DESCRIPTIVE_FLEX_CONTEXT_CODE='Context Name'

11.   Key Flex Fields
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct file_name.ldt KEY_FLEX P_LEVEL=COL_ALL:FQL_ALL:SQL_ALL:STR_ONE:WFP_ALL:SHA_ALL:CVR_ALL:SEG_ALL APPLICATION_SHORT_NAME=”FND” ID_FLEX_CODE=”key flex code” P_STRUCTURE_CODE=”structure name”
12.   Messages
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afmdmsg.lct
XX_MSG.ldt FND_NEW_MESSAGES APPLICATION_SHORT_NAME='FND' MESSAGE_NAME=XX_MSG

13.   AK Region and Attributes
14.   JTF Meta data
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $JTF_TOP/patch/115/import/jtfgrid.lct XX_DS.ldt JTF_GRID_DATASOURCES GRID_DATASOURCE_NAME=XX_DS

15.   Form Personalization
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/affrmcus.lct XX_ARXTWMAI.ldt FND_FORM_CUSTOM_RULES function_name="XX_ARXTWMAI_10"

16.   Printer/Printer Styles
 
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afcpprnt.lct XX_PRINTER.ldt PRINTER PRINTER_NAME ="XXPRN”
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afcppstl.lct XX_PS.ldt STYLE PRINTER_STYLE_NAME=”printer style name”
17.   User Definitions
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $FND_TOP/patch/115/import/afscursp.lct XX_USER.ldt FND_USER USER_NAME='XX_USER'

18.   Alert
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD $ALR_TOP/patch/115/import/alr.lct XX_ALERT1.ldt ALR_ALERTS APPLICATION_SHORT_NAME=FND ALERT_NAME=XX_ALERT1

19.   XMLP Template Data definitions
FNDLOAD $APPSLOGIN O Y DOWNLOAD $XDO_TOP/patch/115/import/xdotmpl.lct XX_ DATA_DEF_NAME.ldt XDO_DS_DEFINITIONS APPLICATION_SHORT_NAME=”XXAR” DATA_SOURCE_CODE=”XX_DATA_DEF_NAME”
a.       XMLP Templates needs to be moved via XDOLOADER utility
java oracle.app.do.ox.until.XDOLoader DOWNLOAD \
-DB_USERNAME $APPS_USER \
-DB_PASSWORD $APPS_PWD \
-JDBC_CONNECTION $JDBC_LOGIN \
-LOB_TYPE <TEMPLATE/XML_SCHEMA> \
-APPS_SHORT_NAME XX_AR \
-LOB_CODE <template code/ DD code> \
-LANGUAGE en \
-TERRITORY US

20.   Attachments
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afattach.lct XX_ATTACMENT.ldt FND_ATTACHMENT_FUNCTIONS APPLICATION_SHORT_NAME="XXAR"

21.   FND Dictionary
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afdict.lct XX_TABLE.ldt FND_TABLE APPLICATION_SHORT_NAME="XXAR"
22.   Document sequences
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afsncat.lct XX_SEQ.ldt FND_DOC_SEQUENCE_CATEGORIES APP_SHORT_NAME ="XXAR”
23.   Concurrent Program Schedules
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afcpsch.lct XX_SCHEDULE.ldt SCHEDULE APPLICATION_SHORT_NAME ="XXAR"
24.   Lookups
FNDLOAD $APPSLOGIN 0 Y DOWNLOAD aflvmlu.lct XX_LKP.ldt FND_LOOKUP_TYPE APPLICATION_SHORT_NAME ='XXAR' LOOKUP_TYPE="XX_LKP1"
25.   Currency/Territory/Language
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afnls.lct XX_CURRENCY.ldt FND_CURRENCY CURR_CODE ="XXINR"
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afnls.lct XX_CURRENCY.ldt FND_TERRITORY TERR_CODE ="XXIND"
FNDLOAD $APPSLOGIN O Y DOWNLOAD $FND_TOP/patch/115/import/afnls.lct XX_CURRENCY.ldt FND_LANGUAGE LANG_CODE ="XXKAN"


Reference for below table:
Description: fnd

1 comment:

  1. Good read. Is it possible to download 2 object in one command? For example,

    $FND_TOP/bin/FNDLOAD apps/apps@dev 0 Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct VALSET.ldt VALUE_SET FLEX_VALUE_SET_NAME="BUSINESS_GROUP_ID" FLEX_VALUE_SET_NAME="CSSM_PAY_PERIOD_START_DATE"

    I tried this but it didn't work out. Do you have a alternate method? I would appreciate if you can share. Thanks!

    ReplyDelete