Monday, November 14, 2016

Java applets taking too much time to load


  1. Open Control Panel
  2. Open Java
  3. Goto Advance Settings
  4. Find "Perform certificate revocation checks on"
  5. Select "Do not check (Not Recommended)"
  6. Click Ok
Retest the application..

Monday, October 31, 2016

API to assign External Bank Account to Supplier -Instrument- in Oracle Apps R12

1:   /*  
2:  API to assign External Bank Account to Supplier (Create Instrument) in Oracle Apps R12 - iby_disbursement_setup_pub  
3:     */  
4:  DECLARE  
5:   p_api_version     NUMBER;  
6:   p_init_msg_list    VARCHAR2(200);  
7:   p_commit        VARCHAR2(200);  
8:   x_return_status    VARCHAR2(200);  
9:   x_msg_count      NUMBER;  
10:   x_msg_data       VARCHAR2(200);  
11:   p_payee        apps.iby_disbursement_setup_pub.payeecontext_rec_type;  
12:   p_assignment_attribs  apps.iby_fndcpt_setup_pub.pmtinstrassignment_rec_type;  
13:   lr_ext_bank_acct_dtl  iby_ext_bank_accounts%ROWTYPE;  
14:   x_assign_id      NUMBER;  
15:   x_response       apps.iby_fndcpt_common_pub.result_rec_type;  
16:   lv_vendor_site_code  VARCHAR2(100);  
17:   lv_vendor_name     VARCHAR2(100);  
18:   lv_bank_acct_name   VARCHAR2(100);  
19:   lv_bank_acct_num    VARCHAR2(100);   
20:   lv_supp_site_id    VARCHAR2(100);  
21:   lv_supp_party_site_id VARCHAR2(100);  
22:   lv_acct_owner_party_id VARCHAR2(100);  
23:   lv_org_id       VARCHAR2(100);  
24:   l_msg         VARCHAR2(200);  
25:   cursor suppliers IS   
26:   SELECT a.supplier_num , a.supplier_name , a.bank_account_num ,a.bank_account_name ,a.iban ,a.currency_code  
27:    , a.site_name   
28:    FROM xx_suppliers a --- your custom table to Load  
29:  ,ce_banks_v b   
30:   ,ce_bank_branches_v c   
31:   ,ap_suppliers s   
32:   ,ap_supplier_sites_all ss   
33:  where 1=1   
34:  and trim(a.supplier_name) = trim(s.vendor_name)  
35:  and ss.vendor_id = s.vendor_id  
36:  and ss.vendor_site_code = a.site_name  
37:  and a.bank_name = b.bank_name  
38:  and b.bank_party_id = c.bank_party_id  
39:  and c.bank_branch_name = a.bank_branch_name  
40:  and ss.org_id = &org_id  
41:  ;  
42:  l_count number:=0;  
43:  BEGIN  
44:  l_count := 0;  
45:   for rec in suppliers loop   
46:   -- Initialize apps session  
47:   fnd_global.apps_initialize(0,20639,200);  
48:   mo_global.init('SQLAP');  
49:   fnd_client_info.set_org_context(&l_org_id);  
50:   -- Input values  
51:   lv_vendor_site_code := rec.site_name;  
52:   lv_vendor_name   := rec.supplier_name;  
53:   lv_bank_acct_name  := rec.bank_account_name;  
54:   lv_bank_acct_num  := rec.bank_account_num;  
55:   -- Assign API parameters  
56:   p_api_version  := 1.0;  
57:   p_init_msg_list := fnd_api.G_FALSE;  
58:   p_commit    := fnd_api.g_true;  
59:   -- get ext bank account details  
60:   BEGIN  
61:    SELECT *  
62:     INTO lr_ext_bank_acct_dtl  
63:     FROM iby_ext_bank_accounts a   
64:     WHERE 1=1   
65:     and nvl(a.bank_account_name,'0') = nvl(lv_bank_acct_name,'0')  
66:     and a.bank_account_num = rec.bank_account_num   
67:     and a.iban = rec.iban   
68:     and a.currency_code = rec.currency_code  
69:     ;  
70:   EXCEPTION  
71:    WHEN OTHERS THEN  
72:     DBMS_OUTPUT.put_line('Unable to derive the external bank details:' ||  
73:                SQLERRM);  
74:   END;  
75:   -- get supplier details  
76:   BEGIN  
77:    SELECT assa.vendor_site_id,  
78:        assa.party_site_id,  
79:        aps.party_id,  
80:        assa.org_id  
81:     INTO lv_supp_site_id,  
82:        lv_supp_party_site_id,  
83:        lv_acct_owner_party_id,  
84:        lv_org_id  
85:     FROM ap_suppliers aps, ap_supplier_sites_all assa  
86:     WHERE aps.vendor_id = assa.vendor_id  
87:      AND aps.vendor_name = lv_vendor_name  
88:      AND assa.vendor_site_code = lv_vendor_site_code;  
89:   EXCEPTION    
90:    WHEN OTHERS THEN  
91:     DBMS_OUTPUT.put_line('Error- Get supp_site_id and supp_party_site_id' ||  
92:                SQLCODE || SQLERRM);  
93:   END;  
94:   -- Assign payee values for supplier header level  
95:   p_payee.supplier_site_id := null;--lv_supp_site_id;  
96:   p_payee.party_id     := lv_acct_owner_party_id;  
97:   p_payee.party_site_id  := NULL; --lv_supp_party_site_id;  
98:   p_payee.payment_function := 'PAYABLES_DISB';  
99:   p_payee.org_id      := NULL;--lv_org_id;  
100:   p_payee.org_type     := NULL;--'OPERATING_UNIT';  
101:   /*  
102:   -- Assign payee values For supplier site leve  
103:   p_payee.supplier_site_id := lv_supp_site_id;  
104:   p_payee.party_id     := lv_acct_owner_party_id;  
105:   p_payee.party_site_id  := lv_supp_party_site_id;  
106:   p_payee.payment_function := 'PAYABLES_DISB';  
107:   p_payee.org_id      := --lv_org_id;  
108:   p_payee.org_type     := --'OPERATING_UNIT';   
109:   */  
110:   ----------------------------------------------------  
111:   -- Assignment Values  
112:   p_assignment_attribs.instrument.instrument_type := 'BANKACCOUNT';  
113:   p_assignment_attribs.instrument.instrument_id  := lr_ext_bank_acct_dtl.ext_bank_account_id;  
114:   -- External Bank Account ID  
115:   p_assignment_attribs.priority  := 1;  
116:   p_assignment_attribs.start_date := '01/01/2016';  
117:   iby_disbursement_setup_pub.set_payee_instr_assignment  
118:    (p_api_version    => p_api_version,  
119:     p_init_msg_list   => p_init_msg_list,  
120:     p_commit       => p_commit,  
121:     x_return_status   => x_return_status,  
122:     x_msg_count     => x_msg_count,  
123:     x_msg_data      => x_msg_data,  
124:     p_payee       => p_payee,  
125:     p_assignment_attribs => p_assignment_attribs,  
126:     x_assign_id     => x_assign_id,  
127:     x_response      => x_response  
128:    );  
129:   DBMS_OUTPUT.put_line('X_RETURN_STATUS = ' || x_return_status);  
130:   DBMS_OUTPUT.put_line('X_MSG_COUNT = ' || x_msg_count);  
131:   DBMS_OUTPUT.put_line('X_MSG_DATA = ' || x_msg_data);  
132:   DBMS_OUTPUT.put_line('X_ASSIGN_ID = ' || x_assign_id);  
133:   DBMS_OUTPUT.put_line('X_RESPONSE.Result_Code = ' ||  
134:              x_response.result_code);  
135:   DBMS_OUTPUT.put_line('X_RESPONSE.Result_Category = ' ||  
136:              x_response.result_category);  
137:   DBMS_OUTPUT.put_line('X_RESPONSE.Result_Message = ' ||  
138:              x_response.result_message);  
139:   IF (x_return_status <> fnd_api.g_ret_sts_success) THEN  
140:    FOR i IN 1 .. fnd_msg_pub.count_msg LOOP  
141:     l_msg := fnd_msg_pub.get(p_msg_index => i,  
142:                  p_encoded  => fnd_api.g_false);  
143:     DBMS_OUTPUT.put_line('The API call failed with error ' || l_msg);  
144:    END LOOP;  
145:   ELSE  
146:  --  DBMS_OUTPUT.put_line('The API call ended with SUCESSS status');  
147:  l_count := l_count + 1 ;  
148:   END IF;  
149:  END LOOP;   
150:  dbms_output.put_line(' Created : '||l_count);  
151:  END;  

Check and validate GL Account

1:  declare   
2:   v_seg_array                    Fnd_Flex_Ext.SegmentArray;  
3:   v_num_of_segments                 NUMBER;  
4:   v_ccid                       NUMBER ;   
5:   v_message                     varchar(1000);             
6:   v_get_comb                     BOOLEAN;  
7:  begin  
8:    v_ccid :=null;  
9:    v_message := null ;  
10:    v_num_of_segments := fnd_flex_ext.breakup_segments(concatenated_segs => '01-000000-000-',delimiter => '-',segments => v_seg_array);  
11:   v_get_comb := fnd_flex_ext.get_combination_id('SQLGL',  
12:                          'GL#',  
13:                          CHAR_OF_ACCOUNT_ID,  
14:                          trunc(sysdate),  
15:                          v_num_of_segments,  
16:                          v_seg_array,  
17:                          v_ccid);  
18:   if v_get_comb = false then  
19:    v_message := fnd_flex_ext.get_message;  
20:      raise_application_error(-20001,'invail Account: /'||v_message );   
21:      else  
22:      dbms_output.put_line('VCCID '||v_ccid ||' num of sements '||v_num_of_segments);    
23:    end if;  
24:   END; ----------------  

Tuesday, October 18, 2016

Simplified and Touch-Friendly User Interface in Oracle E-Business Suite.



Simplified and Touch-Friendly User Interface in Oracle E-Business Suite. In Oracle 12.2.4 and above                                                                       Please follow this link:                                               http://www.slideshare.net/vasuballa/simplified-and-touchfriendly-user-interface-in-oracle-ebusiness-suite








Monday, October 17, 2016

FNDLOAD Folders Script


To Download folders:

FNDLOAD apps/password 0 Y DOWNLOAD $FND_TOP/patch/115/import/fndfold.lct file_name.ldt FND_FOLDERS NAME="%Your Name%"

Upload Script:

FNDLOAD apps/password 0 Y UPLOAD $FND_TOP/patch/115/import/fndfold.lct file_name.ldt


Thursday, June 23, 2016

XML Publisher issues : Error No: 53




Oracle BI Publisher > Preview > PDF/EXCEL 
Get Error:
Error No: 53
Desc: File not found
Please confirm that
1) Java runtime version is 1.3 or later is installed correctly
2) The Java executable is accessible through the Windows Path or the Java Home directory is entered in the Preview tab of the options dialog

Solution1:
Oracle BI Publisher > Tools > Options > Preview Tab
Select correct Java Home by clicking on Browser button next to it.


Sunday, May 29, 2016

Get unsuccessful users login Oracle EBS R12

SELECT *
FROM 
fnd_unsuccessful_logins a where a.user_id =0 
and trunc(a.attempt_time) = trunc(sysdate)
;

Wednesday, May 18, 2016

Resetting Purchase Orders stuck in Pre-Approved status


Problem:Some purchase orders are stuck in the " Pre-Approved " status. How do I reset these purchase orders?

How To Reset a Purchase Order or Requisition From In Process or Pre-Approved (Doc ID 390023.1).
Download patch 21127441 R12.PO.B:
Note:
do not apply rather just extract script poxrespo.sql  and run it individually as a workaround to get past that error. 


sqlplus apps/pass @poxrespo.sql
SQL*Plus: Release 10.1.0.5.0 - Production on Tue May 2 16:32:07 2016
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition
Please enter the PO number to reset : 1122
Please enter the organization id to which the PO belongs (Default NULL) : 81
Do you want to delete the action history since the last approval ? (Y/N) NProcessing STANDARD PO Number: 1122
......................................
Aborting Workflow...
Updating PO Status..
Done Approval Processing.
PL/SQL procedure successfully completed.
SQL> commit;
Commit complete.
SQL> exit
Regards,

Bahaa Barghouti

Wednesday, May 11, 2016

Thursday, April 14, 2016

adop phase=fs_clone [ERROR]: At least one Oracle inventory check has failed.Provide the location of a valid inventory file.


$ <RUN> adop phase=fs_clone
[ERROR]: At least one Oracle inventory check has failed.Provide the location of a valid inventory file.

Solution :

$ <RUN>: cd /oracle/PROD/apps/fs_ne/EBSapps/log/adop/13/fs_clone_<time_cloe>/SID_hostname
$ <RUN>:  vi ADOPValidations_detailed.log

look for the ERROR: in the log file to see what is the ORACLE_HOME or registered in <oraInst.loc>/oraInventory/ContentsXML/inventory.xml

now Register your Oracle Home by using this command:

$<RUN>$  cd $ORACLE_HOME/oui/bin

$<RUN>$ /runInstaller.sh -attachhome ORACLE_HOME=/YOUR_MISSING_HOME ORACLE_HOME_NAME='HOME_NAME'
Attached Successfully 

Rerun: <$RUN>:  adop phase=fs_clone



Wednesday, February 24, 2016

ADOP failes (Clean a previous Session)









Case:
Checking for existing adop sessions.
    Session Id            :   2
    Prepare phase status  :   NOT APPLICABLE
    Apply phase status    :   ATLEAST ONE PATCH IS ALREADY APPLIED
    Cutover  phase status :   NOT APPLICABLE
    Abort phase status    :   NOT APPLICABLE
    Session status        :   FAILED
    [UNEXPECTED]The adop utility cannot be used when a previous patching cycle is incomplete
    [UNEXPECTED]Ensure there is no existing patching cycle before trying to apply more patches
    [UNEXPECTED]Unrecoverable error occurred. Exiting current adop session.

Solution:
 STEP1: Source RUN File System and run the following:
$adop phase=cleanup

The cleanup phase completed successfully.
adop exiting with status = 0 (Success)
$

Regards,
Bahaa Barghouti

How to recreate Oracle Inventory



$ export PATH=$PATH:$ORACLE_HOME/OPatch
$ opatch lsinv
Oracle Interim Patch Installer version 11.2.0.3.12
Copyright (c) 2016, Oracle Corporation.  All rights reserved.
Oracle Home       : /oracle/PROD/db/tech_st/11.2.0
Central Inventory : /oracle/oraInventory
   from           : /oracle/PROD/db/tech_st/11.2.0/oraInst.loc
OPatch version    : 11.2.0.3.12
OUI version       : 11.2.0.4.0
Log file location : /oracle/PROD/db/tech_st/11.2.0/Opatch/opatch2016-02-24_09-53-37AM_1.log
Lsinventory Output file location : /oracle/PROD/db/tech_st/11.2.0/cfgtoollogs/opatch/lsinv/lsinventory2016-02-24_09-53-37AM.txt
--------------------------------------------------------------------------------
Local Machine Information::
Hostname: bbarg-apps.ple.com
ARU platform id: 226
ARU platform description:: Linux x86-64
 Step2:cat ./oraInventory/ContentsXML/inventory.xml
           Check if your Oracle Home listed in the file if not go to next step.

     Step 3. Re-create the Oracle Inventory.
$./runInstaller -silent -attachHome ORACLE_HOME="<Your Oracle Home >" ORACLE_HOME_NAME="OraDbHome"

Now you can apply the patches successfully.

Regarda,
Bahaa Barghouti

R12.2 Adop Does Nothing, Online Patching




 Oracle ADOP do nothing and Hangs.
Case:
adop do nothing when run.



Solution:
Login by root user and run below command:



c Make sure that the hostname in your server the same as the node name in R12.2.

Regards,
Bahaa Barghouti

Thursday, January 21, 2016

Where do concurrent request log files and output files go, Oracle 12.1 12.2


SELECT LOGFILE_NAME, OUTFILE_NAME ,a.request_date ,a.lfile_size/1024/1024 lfile ,a.ofile_size/1024/1024 ofile
 ,b.user_concurrent_program_name
from fnd_concurrent_requests a ,
fnd_concurrent_programs_vl b
where a.request_date between sysdate -4 and sysdate
and a.concurrent_program_id = b.concurrent_program_id

;

Wednesday, January 20, 2016

Get Oracle 12 payment XML output, Custom payment template

Get Oracle 12 payment XML output.
Use the following query to get XML Output for payment to modify the payment template:
Q1:-
SELECT   document
  FROM   iby_trxn_documents
 WHERE   payment_instruction_id = :p_payment_instruction_id;

use the output to build custom payment template

Thanks,