Thursday, May 18, 2017

FND_PROFILE and FND_GLOBAL values

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;

For example, I almost always use the following global variable assignments in my package specification to use throughout the entire package body:

   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);

Monday, May 15, 2017

OiilNativeException is thrown, While Installing Oracle Developer Suite( Forms10g Reports 10g) Installation

Recently we were forced to re-install Oracle Developer suite 10g (10.1.2.0.2) and came across a peculiar error and the installation log out file had the following entries
01
02
03
04
05
06
07
08
09
10
11
OiilNativeException is thrown
OiilNativeException is thrown
OiilNativeException is thrown
OiilNativeException is thrown
OiilNativeException is thrown
path: C:\Users\rthampi\AppData\Local\Temp\OraInstall2013-04-28_08-56-48AM\jre\1.4.2\bin;.;C:\Windows\system32;C:\Windows;D:\oracle\product\10.2.0\db_1\bin;D:\WLS\Middleware\Oracle_FRHome1\bin;C:\orant\bin;C:\orant\jdk\bin;D:\WebLogic\Middleware\Oracle_FRHome1\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Program Files Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Windows Live\Shared;C:\Windows\System32\Windows System Resource Manager\bin;C:\Program Files (x86)\PC Connectivity Solution\;C:\Program Files (x86)\QuickTime\QTSystem\;D:\WLS\Middleware\Oracle_FRHome1\opmn\bin;D:\WLS\Middleware\Oracle_FRHome1\opmn\lib;D:\WLS\Middleware\Oracle_FRHome1\perl\bin;D:\WebLogic\Middleware\Oracle_FRHome1\opmn\bin;D:\WebLogic\Middleware\Oracle_FRHome1\opmn\lib;D:\WebLogic\Middleware\Oracle_FRHome1\perl\bin
toload is C:\Users\rthampi\AppData\Local\Temp\OraInstall2013-04-28_08-56-48AM\WindowsGPortQueries.dll
and by the end of install log file we were able to see that, the installation was terminated while trying to setup LD_LIBRARY_PATH environment variable
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
oracleHomes = C:\orant,D:\DevSuiteHome_1,D:\Oracle\Middleware\oracle_common,D:\oracle\product\10.2.0\db_1,D:\WLS\Middleware\oracle_common,D:\Weblogic\Middleware\oracle_common,D:\WebLogic\Middleware\Oracle_FRHome1,D:\DevSuiteHome_2,
configurationPath = D:\DevSuiteHome_2\j2ee\DevSuite\config\default-web-site.xml
attributeName = port
UDPFlag = null
Query Returned: 8892
Setting variable 's_httpPort' to '8892'. Received the value from the variable calculation.
*** Entering Component: oracle.developer.forms.builder installation
Calling Query generalQueries10.1.0.3.0  getOSName
Query Returned: NT_X86
Setting variable 'SO_EXT' to 'so'. Received the value from the variable calculation.
Calling Query generalQueries10.1.0.3.0  getOSName
Query Returned: NT_X86
Setting variable 'PROD_LIBDIR' to 'lib'. Received the value from the variable calculation.
Calling Query generalQueries10.1.0.3.0  getOSName
Query Returned: NT_X86
Setting variable 'OS_CHECK' to 'NT_X86'. Received the value from the variable calculation.
Calling Query generalQueries10.1.0.3.0  getOSName
Query Returned: NT_X86
Setting variable 'OHOME_LIBDIR' to 'lib'. Received the value from the variable calculation.
Calling Query generalQueries10.1.0.3.0  getenv
name = LD_LIBRARY_PATH
Obvious, we had an installation for Oracle Weblogic Server 10.3.6 and Oracle developer suite 11g which were done much later stages, and the Environment was setup with a static entry for LD_LIBRARY_PATH=D:\WebLogic\Middleware\Oracle_FRHome1\lib;D:\instantclient32
During the installation time, the installer was trying to setup the LD_LIBRARY_PATH variable for sourcing the required files/other components, and failing to setup the same was causing an unexpected error and thus the entire installation failing without producing any specific error within the log file, other than the .out file stating an exception towards “OiilNativeException “
Workaround
Copy the LD_LIBRARY_PATH value to a text file and delete the environment variable after stopping Weblogic services.
Restart the computer and try to install your product. This should solve the dreaded issues with installation.

Tested environment: Windows 8 64Bit Professional edition running Oracle database 10g 10.2.0.3, Oracle weblogic server 10.3.6, Oracle developer suite 11g