PROFILE OPTIONS
PROFILE
OPTIONS IN ORACLE APPS R12 - OVERVIEW (FND PROFILE)
Definition:
Profiles are the changeable options which affect the way Oracle Application runs. Moreover, Moreover, The profile option acts like a Global Variable in Oracle. It is needed to provide the flexibility to Oracle Applications.
Types:
The profiles are of two types those are given below.
1. System Profile and
2. User Profile.
About DIFFERENT LEVELS a Profile value can be set:
The Profile values will be set in different levels those are given below.
1. Site
2. Application
3. Responsibility
4. User
5. Server
6. Organization
Site: This field displays the current value, if set, for all users at the installation site.
Application: This field displays the current value, if set, for all users working under responsibilities owned by the application identified in the Find Profile Values block.
Responsibility: This field displays the current value, if set, for all users working under the responsibility identified in the Find Profile Values block.
User: This field displays the current value, if set, for the application user identified in the Find Profile Values block.
Profile: Enter the name of the profile option whose values you wish to display.
Definition:
Profiles are the changeable options which affect the way Oracle Application runs. Moreover, Moreover, The profile option acts like a Global Variable in Oracle. It is needed to provide the flexibility to Oracle Applications.
Types:
The profiles are of two types those are given below.
1. System Profile and
2. User Profile.
About DIFFERENT LEVELS a Profile value can be set:
The Profile values will be set in different levels those are given below.
1. Site
2. Application
3. Responsibility
4. User
5. Server
6. Organization
Site: This field displays the current value, if set, for all users at the installation site.
Application: This field displays the current value, if set, for all users working under responsibilities owned by the application identified in the Find Profile Values block.
Responsibility: This field displays the current value, if set, for all users working under the responsibility identified in the Find Profile Values block.
User: This field displays the current value, if set, for the application user identified in the Find Profile Values block.
Profile: Enter the name of the profile option whose values you wish to display.
Navigation
to set Profile Values
SYSTEM PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
You may search for profile options using character strings and the wildcard symbol (%). For example, to find all the profile options prefixed by "Concurrent:” you could enter "Conc%" and press the Find button.
PERSONAL PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
To view personal profiles enter into the query mode and enter the profile name which we have already then we get profile value details.
To check the validation done against the Profile value while setting:
Responsibility APPLICATION DEVELOPER -->
Use of the API FND_PROFILE
It is used to perform various actions related to profile values through PL/SQL. Some of the important ones are listed below
1. FND_PROFILE.GET(‘Name of the Profile’, variable name);
Example
SELECT fnd_profile.value('PROFILEOPTION')
,fnd_profile.value('MFG_ORGANIZATION_ID')
,fnd_profile.value('ORG_ID')
,fnd_profile.value('LOGIN_ID')
,fnd_profile.value('USER_ID')
,fnd_profile.value('USERNAME')
,fnd_profile.value('CONCURRENT_REQUEST_ID')
,fnd_profile.value('GL_SET_OF_BKS_ID')
,fnd_profile.value('SO_ORGANIZATION_ID')
,fnd_profile.value('APPL_SHRT_NAME')
,fnd_profile.value('RESP_NAME')
,fnd_profile.value('RESP_ID')
FROM DUAL;
2. variable name := FND_PROFILE.VALUE(‘Name of the profile’);
3. FND_PROFILE.PUT(‘Name of the profile’, value of the profile);
Example
SET SERVEROUTPUT ON;
DECLARE
v_conc_login_id NUMBER;
BEGIN
FND_PROFILE.put ('CONC_LOGIN_ID',1425);
fnd_profile.get ('CONC_LOGIN_ID', v_conc_login_id);
DBMS_OUTPUT.put_line (v_conc_login_id);
END;
Output:
1425
PL/SQL procedure successfully completed
The 1st and 2nd are same but, the only difference is FND_PROFILE.GET is the procedure and FND_PROFILE.VALUE is the function so, it return a value.
Apart from the above procedures we have another important one named FND_PROFILE.SAVE used to set the profile values from backend. A detail regarding this API is available in another article.
The table fnd_profile_options_tl, profile options names are kept. Now find the corresponding the Profile option name for which you need to update from backend. For this example I took my favorite “ORG_ID”
SELECT profile_option_name FROM fnd_profile_options_tl WHERE user_profile_option_name LIKE 'MO%'It returns more than one row but i can make out that "ORG_ID" is the PROFILE_OPTION_NAME for MO: Operating Unit. Now I need to know the Org_ID of the Org whose value is to be set in MO: Operating Unit. SO I use the simple select as below
SELECT organization_id, NAME FROM hr_all_organization_units;
SYSTEM PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
You may search for profile options using character strings and the wildcard symbol (%). For example, to find all the profile options prefixed by "Concurrent:” you could enter "Conc%" and press the Find button.
PERSONAL PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
To view personal profiles enter into the query mode and enter the profile name which we have already then we get profile value details.
To check the validation done against the Profile value while setting:
Responsibility APPLICATION DEVELOPER -->
Use of the API FND_PROFILE
It is used to perform various actions related to profile values through PL/SQL. Some of the important ones are listed below
1. FND_PROFILE.GET(‘Name of the Profile’, variable name);
Example
SELECT fnd_profile.value('PROFILEOPTION')
,fnd_profile.value('MFG_ORGANIZATION_ID')
,fnd_profile.value('ORG_ID')
,fnd_profile.value('LOGIN_ID')
,fnd_profile.value('USER_ID')
,fnd_profile.value('USERNAME')
,fnd_profile.value('CONCURRENT_REQUEST_ID')
,fnd_profile.value('GL_SET_OF_BKS_ID')
,fnd_profile.value('SO_ORGANIZATION_ID')
,fnd_profile.value('APPL_SHRT_NAME')
,fnd_profile.value('RESP_NAME')
,fnd_profile.value('RESP_ID')
FROM DUAL;
2. variable name := FND_PROFILE.VALUE(‘Name of the profile’);
3. FND_PROFILE.PUT(‘Name of the profile’, value of the profile);
Example
SET SERVEROUTPUT ON;
DECLARE
v_conc_login_id NUMBER;
BEGIN
FND_PROFILE.put ('CONC_LOGIN_ID',1425);
fnd_profile.get ('CONC_LOGIN_ID', v_conc_login_id);
DBMS_OUTPUT.put_line (v_conc_login_id);
END;
Output:
1425
PL/SQL procedure successfully completed
The 1st and 2nd are same but, the only difference is FND_PROFILE.GET is the procedure and FND_PROFILE.VALUE is the function so, it return a value.
Apart from the above procedures we have another important one named FND_PROFILE.SAVE used to set the profile values from backend. A detail regarding this API is available in another article.
The table fnd_profile_options_tl, profile options names are kept. Now find the corresponding the Profile option name for which you need to update from backend. For this example I took my favorite “ORG_ID”
SELECT profile_option_name FROM fnd_profile_options_tl WHERE user_profile_option_name LIKE 'MO%'It returns more than one row but i can make out that "ORG_ID" is the PROFILE_OPTION_NAME for MO: Operating Unit. Now I need to know the Org_ID of the Org whose value is to be set in MO: Operating Unit. SO I use the simple select as below
SELECT organization_id, NAME FROM hr_all_organization_units;
Navigation
to set Profile Values
SYSTEM PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
You may search for profile options using character strings and the wildcard symbol (%). For example, to find all the profile options prefixed by "Concurrent:” you could enter "Conc%" and press the Find button.
PERSONAL PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
To view personal profiles enter into the query mode and enter the profile name which we have already then we get profile value details.
To check the validation done against the Profile value while setting:
Responsibility APPLICATION DEVELOPER -->
Use of the API FND_PROFILE
It is used to perform various actions related to profile values through PL/SQL. Some of the important ones are listed below
1. FND_PROFILE.GET(‘Name of the Profile’, variable name);
Example
SELECT fnd_profile.value('PROFILEOPTION')
,fnd_profile.value('MFG_ORGANIZATION_ID')
,fnd_profile.value('ORG_ID')
,fnd_profile.value('LOGIN_ID')
,fnd_profile.value('USER_ID')
,fnd_profile.value('USERNAME')
,fnd_profile.value('CONCURRENT_REQUEST_ID')
,fnd_profile.value('GL_SET_OF_BKS_ID')
,fnd_profile.value('SO_ORGANIZATION_ID')
,fnd_profile.value('APPL_SHRT_NAME')
,fnd_profile.value('RESP_NAME')
,fnd_profile.value('RESP_ID')
FROM DUAL;
2. variable name := FND_PROFILE.VALUE(‘Name of the profile’);
3. FND_PROFILE.PUT(‘Name of the profile’, value of the profile);
Example
SET SERVEROUTPUT ON;
DECLARE
v_conc_login_id NUMBER;
BEGIN
FND_PROFILE.put ('CONC_LOGIN_ID',1425);
fnd_profile.get ('CONC_LOGIN_ID', v_conc_login_id);
DBMS_OUTPUT.put_line (v_conc_login_id);
END;
Output:
1425
PL/SQL procedure successfully completed
The 1st and 2nd are same but, the only difference is FND_PROFILE.GET is the procedure and FND_PROFILE.VALUE is the function so, it return a value.
Apart from the above procedures we have another important one named FND_PROFILE.SAVE used to set the profile values from backend. A detail regarding this API is available in another article.
The table fnd_profile_options_tl, profile options names are kept. Now find the corresponding the Profile option name for which you need to update from backend. For this example I took my favorite “ORG_ID”
SELECT profile_option_name FROM fnd_profile_options_tl WHERE user_profile_option_name LIKE 'MO%'It returns more than one row but i can make out that "ORG_ID" is the PROFILE_OPTION_NAME for MO: Operating Unit. Now I need to know the Org_ID of the Org whose value is to be set in MO: Operating Unit. SO I use the simple select as below
SELECT organization_id, NAME FROM hr_all_organization_units;
SYSTEM PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
You may search for profile options using character strings and the wildcard symbol (%). For example, to find all the profile options prefixed by "Concurrent:” you could enter "Conc%" and press the Find button.
PERSONAL PROFILE:
Responsibility SYSTEM ADMINISTRATOR -->
To view personal profiles enter into the query mode and enter the profile name which we have already then we get profile value details.
To check the validation done against the Profile value while setting:
Responsibility APPLICATION DEVELOPER -->
Use of the API FND_PROFILE
It is used to perform various actions related to profile values through PL/SQL. Some of the important ones are listed below
1. FND_PROFILE.GET(‘Name of the Profile’, variable name);
Example
SELECT fnd_profile.value('PROFILEOPTION')
,fnd_profile.value('MFG_ORGANIZATION_ID')
,fnd_profile.value('ORG_ID')
,fnd_profile.value('LOGIN_ID')
,fnd_profile.value('USER_ID')
,fnd_profile.value('USERNAME')
,fnd_profile.value('CONCURRENT_REQUEST_ID')
,fnd_profile.value('GL_SET_OF_BKS_ID')
,fnd_profile.value('SO_ORGANIZATION_ID')
,fnd_profile.value('APPL_SHRT_NAME')
,fnd_profile.value('RESP_NAME')
,fnd_profile.value('RESP_ID')
FROM DUAL;
2. variable name := FND_PROFILE.VALUE(‘Name of the profile’);
3. FND_PROFILE.PUT(‘Name of the profile’, value of the profile);
Example
SET SERVEROUTPUT ON;
DECLARE
v_conc_login_id NUMBER;
BEGIN
FND_PROFILE.put ('CONC_LOGIN_ID',1425);
fnd_profile.get ('CONC_LOGIN_ID', v_conc_login_id);
DBMS_OUTPUT.put_line (v_conc_login_id);
END;
Output:
1425
PL/SQL procedure successfully completed
The 1st and 2nd are same but, the only difference is FND_PROFILE.GET is the procedure and FND_PROFILE.VALUE is the function so, it return a value.
Apart from the above procedures we have another important one named FND_PROFILE.SAVE used to set the profile values from backend. A detail regarding this API is available in another article.
The table fnd_profile_options_tl, profile options names are kept. Now find the corresponding the Profile option name for which you need to update from backend. For this example I took my favorite “ORG_ID”
SELECT profile_option_name FROM fnd_profile_options_tl WHERE user_profile_option_name LIKE 'MO%'It returns more than one row but i can make out that "ORG_ID" is the PROFILE_OPTION_NAME for MO: Operating Unit. Now I need to know the Org_ID of the Org whose value is to be set in MO: Operating Unit. SO I use the simple select as below
SELECT organization_id, NAME FROM hr_all_organization_units;
===================================================================
Following are the FND_PROFILE values that can be used in the PL/SQL code:
fnd_profile.value('PROFILEOPTION');
fnd_profile.value('MFG_ORGANIZATION_ID');
fnd_profile.value('ORG_ID');
fnd_profile.value('LOGIN_ID');
fnd_profile.value('USER_ID');
fnd_profile.value('USERNAME');
fnd_profile.value('CONCURRENT_REQUEST_ID');
fnd_profile.value('GL_SET_OF_BKS_ID');
fnd_profile.value('SO_ORGANIZATION_ID');
fnd_profile.value('APPL_SHRT_NAME');
fnd_profile.value('RESP_NAME');
fnd_profile.value('RESP_ID');
Following are the FND_GLOBAL values that can be used in the PL/SQL code:
FND_GLOBAL.USER_ID;
FND_GLOBAL.APPS_INTIALIZE;
FND_GLOBAL.LOGIN_ID;
FND_GLOBAL.CONC_LOGIN_ID;
FND_GLOBAL.PROG_APPL_ID;
FND_GLOBAL.CONC_PROGRAM_ID;
FND_GLOBAL.CONC_REQUEST_ID;
g_user_id PLS_INTEGER := fnd_global.user_id;
g_login_id PLS_INTEGER := fnd_global.login_id;
g_conc_req_id PLS_INTEGER := fnd_global.conc_request_id;
g_org_id PLS_INTEGER := fnd_profile.value('ORG_ID');
g_sob_id PLS_INTEGER := fnd_profile.value('GL_SET_OF_BKS_ID');
And initialize the application environment as follows:
v_resp_appl_id := fnd_global.resp_appl_id;
v_resp_id := fnd_global.resp_id;
v_user_id := fnd_global.user_id;
FND_GLOBAL.APPS_INITIALIZE(v_user_id,v_resp_id, v_resp_appl_id);
No comments:
Post a Comment