R12
R12
1. Kindly follow the instructions given below to apply the data fix patch.
AP.A Customers:
AP.B Customers:
NOTE: The instance does not need to be brought down to apply the data-fix patch and
can be applied in hotpatch mode (e.g. adpatch option=hotpatch). Additionally, the scripts
can be manually run anytime after the patch is applied, if needed.
AP.C Customers: NOTE: AP.C patches are online patching enabled, so follow
below instructions carefully:
$AP_TOP/patch/115/sql/ap_wrong_bal_segment_sel.sql
$AP_TOP/patch/115/sql/ap_wrong_bal_segment_fix.sql
NOTE : If customer instance has any active patch edition (i.e. PREPARE phase is done but
CUTOVER is pending), Then they can not apply this patch as HOTPATCH until cutover is
done.
In case of super emergency and customer cannot wait till CUTOVER to Apply this
patch, then refer to Note 1582525.1
The patch delivers 2 scripts and the latest data-fix framework package code:
File Name Purpose
ap_wrong_bal_segment_sel.sql Select script used to find and report the problem data.
ap_wrong_bal_segment_fix.sql Fix script used to fix the problem data.
apgdfalb.pls, Source Code of the latest data-fix framework server-side API
apgdfals.pls - package AP_ACCTG_DATA_FIX_PKG. This package
provides procedures and functions used by the GDF e.g.
backing up the data,displaying the data, etc.
IMPORTANT: Make sure
package AP_ACCTG_DATA_FIX_PKG (both
SPECIFICATION and BODY) is VALID before running the
scripts.
Parameters:
EMAIL FEATURE
This is an optional feature provided to Customers. After execution of GDF selection and fix
scripts, output files will be emailed to the user.
For more information on this feature, please refer to Metalink Note: 1582550.1. To make use
of this feature, pass valid email_id at the
time of script execution. This feature can be ignored by not passing any email_id at the time
of script execution.
Note: Due to technical/security issues if email is not delivered, then customers are advised to
run the scripts by not passing email_id at the
time of script execution. This will not impact actual behavior of datafix.
3. After running the script ap_wrong_bal_segment_sel.sql check the following to verify the
problem transaction(s) were picked up:
1. Driver table AP_TEMP_DATA_DRIVER_9978924
2. Log file 9978924-diag-<HH24:MI:SS>.html which shows affected records.
Run this select to find the location of the log files:
SELECT decode(instr(value,','),0,value, SUBSTR (value,1,instr(value,',') - 1)) FROM
V$Parameter WHERE name = 'utl_file_dir' ;
NOTE: If the transaction(s) in question is not found, it is possible the transaction(s) do not
meet the conditions of the select script. Please provide the Log files to BSA to update in
Oracle SR. Do not proceed to next steps if no transactions are found.
4. Use the following SQL statement (or similar one) to update the process_flag
and NEW_BALANCING_SEG_VALUE or NEW_CODE_COMBID or NEW_CONCAT_ACCOUNT of the
driver table AP_TEMP_DATA_DRIVER_9978924 for the transactions(s) that should be fixed.
1. Update the driver table AP_TEMP_DATA_DRIVER_9978924 with either the required
NEW_BALANCING_SEG_VALUE or NEW_CODE_COMBID or NEW_CONCAT_ACCOUNT
before proceeding with the fix.
COMMIT ;
However, if multiple transactions were detected, then run:
UDATE AP_TEMP_DATA_DRIVER_9088967 DRV
SET DRV.process_flag = 'Y', DRV.NEW_CODE_COMBID = '&CCID'
WHERE ( DRV.invoice_ID ) IN ( ##### , #####, ..., ##### ) ;
-- Note: ##### , #####, ..., ##### represents the list of Invoice_IDs to update.
COMMIT ;
5. Manually run the script ap_wrong_bal_segment_fix.sql to fix the identified (and marked
to fix) transactions.
Example:
sqlplus [apps_user]/[apps_password]@[instance]
@$AP_TOP/patch/115/sql/ap_wrong_bal_segment_fix.sql
The script will prompt user for below inputs.
P_User_Name (Mandatory) [STRING] : KRISHNA.TUMMALA
==========================================================
===============================================
Provide Application User Name in upper case.
This value should be of an application user who has access to invoice/payment and can run
accounting for invoice/payment.
For Example: CBROWN
The user id of this user will be updated in column LAST_UPDATED_BY, and SYSDATE will be
updated in LAST_UPDATE_DATE to keep audit trail.
Note: Make sure you are using a responsibility name and user name for a Payables
responsibility and associated user that has access to run accounting for the subject transaction.
P_Email_Id (Optional) [STRING] :
==================================================
If user wants to receive the generated logs on their email id.
6. After running script ap_wrong_bal_segment_fix.sql, check the following to verify the fix
was successful and no errors or failures occurred:
1. The user entered values in driver table AP_TEMP_DATA_DRIVER_9978924
for NEW_BALANCING_SEG_VALUE or NEW_CODE_COMBID or
NEW_CONCAT_ACCOUNT would be validated to confirm they are valid and accordingly
the VALIDATE_FLAG in the table shall be updated.
8. If you encounter any issue or the results are not the expected, please submit a new Service
Request (SR) with Oracle support and supply the following:
1. Data-Fix scripts log files:
9978924-diag-<HH24:MI:SS>.html
9978924-fix-<HH24:MI:SS>.html
2. Data dump (SELECT * FROM) of the driver and backup tables created by the data-fix
scripts:
AP_TEMP_DATA_DRIVER_9978924
AP_INV_DISTS_9978924_BKP
AP_INV_LINES_9978924_BKP
AP_SA_TAX_DIST_9978924_BKP
ZX_RNREC_DIST_9978924_BKP
3. For the problem Invoice or a sample (2 to 3) of problem Invoices not fixed, run and
upload fresh analyzers:
o "EBS Payables Invoice and EBTax Analyzer".
o "R12: AP: Master GDF Diagnostic (MGD) Analyzer To Validate Data Related To
Invoices, Payments, Accounting, Suppliers And EBTax".