Saturday, 26 January 2013

API to Update External Payee

Whenever a supplier/supplier site is created oracle system will automatically create a payee for the supplier and supplier site. Once the Payee is created the user may want to update the payee details.
The API to update the payee is :

IBY_DISBURSEMENT_SETUP_PUB.update_external_vendor

iby_disbursement_setup_pub.update_external_payee 
 (p_api_version => 1.0, 
   p_init_msg_list => fnd_api.g_true, 
p_ext_payee_tab => p_external_payee_tab_type, 
p_ext_payee_id_tab => p_ext_payee_id_tab_type, 
x_return_status => x_return_status, 
x_msg_count => x_msg_count, 
x_msg_data => x_msg_data, 
x_ext_payee_status_tab => l_payee_upd_status 
);

p_external_payee_tab_type is a table type variable of external payees which will take in a number of fields of the table.

p_ext_payee_id_tab_type is a table type variable which will take in only variable : ext_payee_id

When updating an external payee the developer needs to consider the below:
   the api will update all the columns which defined in the record type variable which is passed to the API , thus the developer when assigning values to the record type variable needs to assigne the new values to be updated as well as the old values to the API rec type.

The data updated will be reflected in the table iby_external_payees_all

Saturday, 19 January 2013

Difference between Value sets and Lookups

Value sets and Lookups might look similar and confuse some people but there are some basic differences between the two.

Difference 1
Value sets can be attached to parameters of a concurrent program, whereas Lookups can't.

Difference 2
Certain types of Lookups are maintainable by the users too, for example HR Users will maintain "Ethnic Minority" lookups. Value Sets are almost never maintained by end users, with the exception of GL Flexfield codes. Value sets are usually maintained by System Administrators.

Difference 3
Value sets can contain values that are a result of an SQL Statement.
Hence it is possible to make Value Set list of values dynamic.
On the contrary, Lookup Codes are Static list of values.

Lookups in Oracle

Lookups in Oracle are a collection of values. Lookups are a static collection of codes which are used by oracle for working.

For Example in a form/table if there is a field for Gender rather than storing the values , Male/Female/Unknown the system may prefer to store codes M/F/U . Thus when storing the values rather than storing the description oracle will store the codes M/F/U and display the complete menaning to the user.

Each lookup when defined will have a lookup code and a corresponding meaning for that code. Oracle will internally use codes for working and use meaning when communicating to the user.

Lookup codes are mainly used when working with forms and handling data in the tables.

When ever a lookup is created and entry will be created in the table FND_LOOKUP_TYPES ,

For each lookup type when the value is entered for the lookup entries will be created in the table FND_LOOKUP_VALUES

For the lookups already defined in Oracle each is associated with an application , thus when searching for application specific lookups user should search with the specific application.

Lookups in Oracle are of 3 types:


  1. System: These are lookups which are used internally by the system. Users can see and use the lookup but they cannot disable the existing values or add new values.
  2. Extensible : These are system provided lookups. Users can add their values if they want , but Seeded values by Oracle cannot be changed 
  3. User Defined : User Defined lookups are client specific which are created to meet the business specific customization's. These are created by the users and the users can add new values and disable the older ones.