Template Form in Oracle Applications

Template Form in Oracle Apps

This document provides an overview of the template form. This form derives its importance from the fact that this form is the starting point of all development involving forms. The document highlights the importance of Template.fmb in forms development and also provides a detailed explanation of the various components of the Template form.

Overview of the Template Form

The TEMPLATE form is the starting point for all development of new forms. The first step in creating a form for use in Oracle Applications is to copy the template form from $AU_TOP/forms/US, to a local directory and renaming it.

The Template form is unique because it contains some special libraries and triggers that render the application using the template form some standard characteristics. The components of the template form are:

· References to object groups: The template form contains platform–independent references to predefined standard object groups in the APPSTAND form. STANDARD_PC_AND_VA, STANDARD_TOOLBAR, and STANDARD_CALENDAR).

· Libraries: The template form contains platform–independent attachments of several libraries (including FNDSQF, APPCORE, and APPDAYPK).

· Special triggers: The template form contains several form–level triggers with required code. These are responsible for standard the behavior of the form.

· Predefined Program Units: The template form contains predefined program units that include a spec and a body for the package APP_CUSTOM, which contains default behavior for window opening and closing events.

· Applications Color Palette: The template form contains the application color palette. This gives the forms developed using the template form the look and feel of Oracle Applications

· Many referenced objects (from the object groups) that support the Calendar, the toolbar, alternative regions, and the menu. These objects include LOVs, blocks, parameters, and property classes, and so on.

· The TEMPLATE form contains sample objects that can be seen as examples for the expected layout cosmetics. These samples can be completely removed from the form later as they are only examples and are not required. The following objects are the samples and can be removed:



§ Canvas–view: BLOCKNAME

Hence, the template form comes along with many attachments, predefined program units, and defined visual attributes as well as examples that not only give the forms that are developed using the template.fmb a standard look and feel, but also make t easier to develop forms with consistent and standard functionality.

Libraries in the Template form

As stated above, the template form contains platform–independent attachments of several libraries. These libraries are used while running the form as a part of Oracle Applications. Hence, these libraries should not be changed or modified. There are three main libraries that are attached to the template form:


APPCORE: APPCORE contains the packages and procedures that are responsible for the standard ‘Oracle Applications’ behavior of the forms. The forms have to support the menu, toolbar, and other required standard behaviors in compliance with oracle applications. The Oracle Applications forms also have to display specific runtime behaviors in accordance with the Oracle Applications Interface Standards, such as the way in which fields are enabled, behaviors of specific types of windows etc. APPCORE contains the procedures to support this standard runtime behavior. APPCORE also contains various other utilities for exceptional handling, message levels, and so on.

APPDAYPK: The APPDAYPK library contains the packages that control the Oracle Applications Calendar feature. The calendar (or the date picker) is a utility that oracle apps provide to pick the dates for a date type field.

FNDSQF: FNDSQF contains packages and procedures for Message Dictionary, flexfields, profiles, and concurrent processing. It also has various other utilities for navigation, multicurrency, WHO, etc.

Other Libraries à The template form also contains a few other libraries that are not linked directly to the template form, but are linked to the three libraries listed above. Although, while using the form it makes no difference whether the library is linked directly to template or to another library that is linked to template. These are discussed below.

CUSTOM library: The CUSTOM library (CUSTOM.pll) is probably the most widely used and customized in the libraries attached to the template form. This library allows extension of Oracle Applications forms without modification of Oracle Applications code. Any form goes to the CUSTOM.pll whenever any event fires on the form. Code can be written in the CUSTOM.pll with the logic branching based on the form, block and trigger on which you want it to run.

You can use the CUSTOM library for customizations such as Zoom (such as moving to another form and querying up specific records), enforcing business rules (for example, vendor name must be in uppercase letters), and disabling fields that do not apply for your site.

GLOBE: The GLOBE library allows Oracle Applications developers to incorporate global or regional features into Oracle Applications forms
without modification of the base Oracle Applications form. Oracle Applications sends events to the GLOBE library. Regional code can
take effect based on these events. The GLOBE library calls routines in
the JA, JE, and JL libraries.

VERT: The VERT library allows Oracle Applications developers to incorporate vertical industry features (for automotive, consumer packaged goods, energy, and other industries) into Oracle Applications forms without modification of the base Oracle Applications form. Oracle Applications sends events to the VERT library. Vertical industry code can take effect based on these events. The VERT library calls routines in various other libraries.

JA: The JA library contains code specific to the Asia/Pacific region and is called by the GLOBE library.

JE: The JE library contains code specific to the EMEA (Europe/ MiddleEast/ Africa) region and is called by the GLOBE library.

JL: The JL library contains code specific to the Latin America region and is called by the GLOBE library.

Thanks Shivmohan Purohit

How to restrict functions and menus available to a user in menus

Hello Friends, Using this article, i wanted to give brief on how we can exclude some forms/ function as security in oracle applications. plz see i am trying to use two different way to get the same functionality.
There are two possibilities:
A – Restrict an existing menu:
1) Log in as System Administrator responsibility
2) Find the name of the appropriate menu      Navigator: Application -> Menu
3) Create a new responsibility       Navigator: Security -> Responsibility -> Define
4) Assign the appropriate menu to the new responsibility
5) Enter functions in the Function and Menu Exclusions section of the form Responsibilities
6) Save
7) Assign the new responsibility to the appropriate user

Example:  Restrict a user to be able to do only Assignments in the Asset Workbench.
1) Log in as the System Administrator responsibility
2) Find the name of the appropriate menu:
Description: %Asset%
2) Create a new responsibility: ASSET – assignments
3) Assign the menu FA_TRANSACTION to the responsibility ASSET – assignements
4) Enter all functions from the LOV in the Function and Menu Exclusions
section except of the Responsibilities form except “Asset Workbench” and
5) Save
6) Assign the responsibility ASSET – assignments to the appropriate user

B – Create a new menu:
1) log in as System Administrator responsibility
2) Create a new menu: Navigator: Application -> Menu      The new menu should contain only the functions and menus which should be accessible for the user.
3) Create a new responsibility       Navigator: Security -> Responsibility -> Define
4) Assign the appropriate menu to the new responsibility
5) Save
6) Assign the new responsibility to the appropriate user

Example:  Restrict a user to be able to do only Assignments in the Asset Workbench.
1) Log in with the System Administrator responsibility
2) Create the new menu menu:
Navigator: Application -> Menu
User Menu Name: FA Assignement
Description: FA Assignement
Seq: 1 Navigator Prompt: Assignment Function: Asset Workbench
Seq: 2 Navigator Prompt: Assignment Function: Assets:Assignements
3) Create a new responsibility: ASSET – assignments
4) Assign the menu FA_ASSIGN to the responsibility ASSET – assignements
5) Save
6) Assign the responsibility ASSET – assignments to the appropriate user

Please share your feedback and also if you think this article is helpful for you. or if this is difficult to understand and use, so i can improve on my future articles. thanks – Shivmohan Purohit

Distinction between configuration, personalization, and extensibility.

Distinction between configuration, personalization, and extensibility.

Configuration provides setup and administrative choices using the native features of the product. Some configuration examples include:

  • Profile Options
  • User-defined fields (Flexfield)
  • Function Security Setup
  • Data Security Setup
  • and a lot more….

Personalization enables you to declaratively tailor the UI look-and-feel, layout or visibility of page content to suit a business need or a user preference. Some personalization examples include:

  • Tailor the order in which table columns are displayed.
  • Tailor a query result.
  • Tailor the color scheme of the UI.
  • Folder Forms
  • Forms Personalization
  • Oracle Application Framework (OAF)

Extensibility is about extending the functionality of an application beyond what can be done through personalization. Some extensibility examples include:

  • Add new functional flows
  • Extend or override existing business logic
  • Using Oracle Forms Developer, Oracle JDeveloper and Oracle Workflow

Oracle Forms Development (Developer 2000) : Part 1

Question: Which triggers are created when master -detail relation?

1) master delete property*  NON-ISOLATED (default)
a) on check delete master
b) on clear details
c) on populate details
a) on clear details
b) on populate details
a) per-delete
b) on clear details
c) on populate details

Question: which system variables can be set by users?







Question: What are object group?
Answer: An object group is a container for a group of objects. You define an object group when you want to package related objects so you can copy or reference them in another module.

Question: What are referenced objects?

Answer: Referencing allows you to create objects that inherit their functionality and appearance from other objects. Referencing an object is similar to copying an object, except that the resulting reference object maintains a link to its source object. A reference object automatically inherits any changes that have been made to the source object when you open or regenerate the module that contains the reference object. 


Question: Can you issue DDL in forms?
Answer: yes, but you have to use FORMS_DDL.

Restrictions: The statement you pass to FORMS_DDL may not contain bind variable

references in the string, but the values of bind variables can be concatenated into the string before passing the result to FORMS_DDL.   
Question: What is SECURE property?


Answer: – Hides characters that the operator types into the text item.  This setting is typically used for  password protection.





Question: What are the types of triggers and how the sequence of firing in text item
Answer: Triggers can be classified as Key Triggers, Mouse Triggers ,Navigational Triggers.
Key Triggers: Key Triggers are fired as a result of Key action.e.g :: Key-next-field, Key-up,Key-Down
Mouse Triggers: Mouse Triggers are fired as a result of the mouse navigation.e.g. When-mouse-button-presed,when-mouse-doubleclicked,etc
Navigational Triggers :: These Triggers are fired as a result of Navigation. E.g :  Post-Text-item,Pre-text-item.
We also have event triggers like when –new-form-instance and when-new-block-instance. We cannot call restricted procedures like go_to(‘my_block.first_item’) in the Navigational triggers But can use them in the Key-next-item.

The Difference between Key-next and Post-Text is an very important question. The key-next is fired as a result of the key action while the post text is fired as a result of the mouse movement. Key next will not fire unless there is a key event.
The sequence of firing in a text item are as follows::
    a) pre – text
    b) when new item
    c) key-next
    d) when validate
    e) post text 


Question: Can you store pictures in database? How?

Answer: Yes, in long raw datatype. 


Question: What are property classes? Can property classes have trigger?

Answer: Property class inheritance is a powerful feature that allows you to quickly define objects that conform to your own interface and functionality standards. Property classes also allow you to make global changes to applications quickly.  By simply changing the definition of a property class, you can change the definition
of all objects that inherit properties from that class. Yes. All type of triggers. 


Question: If you have property class attached to an item and you have same trigger written for the item.  Which will fire first?
Answer: Item level trigger fires , If item level trigger fires, property level trigger won’t fire. Triggers at the lowest level are always given the first preference. The item level trigger fires first and then the block and then the Form level trigger.
Question: What are record groups?  Can record groups created at run-time?

Answer: A record group is an internal Oracle Forms data structure that has a column/row framework similar to a database table.  However, unlike database tables, record groups are separate objects that belong to the form module in which they are defined.  A record group can have an unlimited number of columns of type CHAR, LONG, NUMBER, or DATE provided that the total number of columns does not exceed 64K.  Record group column names cannot exceed 30 characters.Programmatically, record groups can be used whenever the functionality offered by a two-dimensional array of multiple data types is desirable.
Query Record Group    A query record group is a record group that has an associated SELECT statement. 

The columns in a query record group derive their default names, data types, and lengths from the database columns referenced in the SELECT statement.  The records in a query record group are the rows retrieved by the query associated with that record group.
Non-query Record Group: A non-query record group is a group that does not have an associated query, but whose structure and values can be modified programmatically at runtime.
Static Record Group: A static record group is not associated with a query; rather, you define its structure and row values at design time, and they remain fixed at runtime.


 Shivmohan Purohit



Oracle Applications – FNDLOAD Utility

Hello Friend, here is the long awaited and most demanding article on FNDLOAD. The Generic Loader (FNDLOAD) is a concurrent program that can transfer Oracle Application entity data between database and text file.The loader reads a configuration file to determine which entity to access.

1 – Printer Styles

FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afcppstl.lct file_name.ldt STYLE PRINTER_STYLE_NAME=”printer style name” 

2 – Lookups


3 – Descriptive Flexfield with all of specific Contexts
FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/aflvmlu.lct file_name.ldt FND_LOOKUP_TYPE APPLICATION_SHORT_NAME=”FND”
LOOKUP_TYPE=”lookup name”



4 – Key Flexfield Structures



5 – Concurrent Programs


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afcpprog.lct file_name.ldt PROGRAM APPLICATION_SHORT_NAME=”FND” CONCURRENT_PROGRAM_NAME=”concurrent name” 

6 – Value Sets


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct file_name.ldt VALUE_SET_VALUE FLEX_VALUE_SET_NAME=”value set name” 

7 – Value Sets with values


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct file_name.ldt VALUE_SET FLEX_VALUE_SET_NAME=”value set name” 

8 – Profile Options


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afscprof.lct file_name.ldt PROFILE PROFILE_NAME=”profile option” APPLICATION_SHORT_NAME=”FND” 

8 – Request Groups


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct file_name.ldt REQUEST_GROUP REQUEST_GROUP_NAME=”request group” APPLICATION_SHORT_NAME=”FND” 

10 – Request Sets


11 – Responsibilities
FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct file_name.ldt REQ_SET


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afscursp.lct file_name.ldt FND_RESPONSIBILITY RESP_KEY=”responsibility” 

12 – Menus


FNDLOAD apps/apps O Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct file_name.ldt MENU MENU_NAME=”menu_name” 





Reference: Oracle Application System Administrator’s Guide Appendix C has detail description on the usage of loaders. Thanks – Shivmohan Purohit







Create a menu function to launch a concurrent request , request group and a request set

Hello Friends, here again i trying to share very smart and easy way to do very secure feature to run either particular request/ program or a request set or a certain request group using a menu option and attaching “standard request submission” form.

How to create a menu function to launch a concurrent request , request group and a request set ?

Create a Function and assign Form name “Run Reports”
Request Group:



Request Set : Pass parameters REQUEST_SET_NAME = “< Name >”   SET_APPL_SHORT_NAME =”< Name>”      SUBMIT_ONCE  (default ’N’) Note :      SUBMIT_ONCE can be set to either Y or N ( N is the default).      SUBMIT_ONCE is used in conjunction with CONCURRENT_PROGRAM_NAME or REQUEST_SET_NAME.      If SUBMIT_ONCE is set to Y, then the form will exit after the Submit button is clicked.


Thanks, do share your feedback n comments.

Oracle Applications – development, customization, extension

Oracle Supported way to include business needs without creating real customization

When developing with the Oracle eBusiness Suite, there are situations where Developers can use “hooks” in standard Applications code to insert or redirect to custom code. Oracle Applications provide some helpful layers of abstraction to make life easier for customization. Where possible it is nice for this to be done using a supported method. If a true blue customization is required, then its best to try to preserve the existing code so that any future upgrades are more likely to break your custom code by reverting to standard code, plus if you use a “hook” to independent code it is easier to maintain and upgrade the custom code. I regularly use a “copy and modify” approach to Apps Development where I use hooks to call the new code.

Concurrent Program Executable. Where an concurrent program is automagically submitted from a form or another concurrent process, e.g. “Print Pack Slip” in Oracle Shipping actions, as long as parameter requirements are the same, then a quick an easy method to code your own report is: Create a new executable registered under your custom application, e.g. XMODS_WSHRDPAK, Query the called concurrent program and update the executable to your custom executable, e.g. Query WSHRDPAK and replace executable with XMODS_WSHRDPAK

Personalization – Forms and Framework (OAF) plus CUSTOM.pll. Forms PL/SQL Library. Personalization has provided functionality to cover alot of the customizations traditionally coded to CUSTOM.pll, but both Personalization and CUSTOM.pll provide a number of hooks into the front end logic.

Database Triggers. Triggers on tables used carefully can provide hooks where all other methods don’t dare to tread. Of course watch out for the exception and try to avoid putting triggers on fnd_concurrent_requests!

Menu. Provides a prominent method to call new Forms, while potentially hiding behind the same prompt, Reports, Discoverer Workbooks, external links/URLs, etc. Gives the ability to save in the “Favourites” list. If you need to customize a standard form, copy it and create a new menu entry where possible.

Unix Softlink. An alternative to the concurrent program executable hook. Backup an existing standard Oracle file. Remove the existing standard Oracle file. Replace with a softlink to a file under you custom application code “top” directory

Workflow. Workflow customizations are “allowed” and a method I use here is to take a standard function call in workflow, copy and modify the underlying package, then change the function call in workflow to the custom function. E.g. AP Remittance Advice workflow (APPEWF) has “Get Check Info” function calling AP_PAYMENT_EVENT_WF_PKG.get_check_info. Copy AP_PAYMENT_EVENT_WF_PKG to XMODS_AP_PAYMENT_EVENT_WF_PKG and change function in workflow function “Get Check Info”

Printer Driver. Whenever concurrent request file post processing is required, e.g. to FTP or email a file – printer drivers provide an excellent way to perform post processing. Create a new printer driver with the appropriate command. Remember to restart the concurrent manager to pickup updates to print drivers.

Business Events. Not a widely used mechanism, but provides supported hooks into key events such as Payment Confirmations (AP Payment event).

Thanks – Shivmohan Purohit