Answered Questions

Q. What is oracle apps support team responsibilities in the real time? what they will support for the client?

Q. how to develope an XML reports?give me the process steps also

Q. How can we display header information for every page while developing XML report?

Q. How to move the report from one instance to another instance.

Q. Tell me about Order to cash flow ?

Q. When the order is closed. in O to cash.

Q. what is the difference between oracle fincial and oracle purchasing.Is oracle purchasing coming under oracle fincial

Q. Difference between filler and skip

Q. Hello,
What is the difference b/w Dropshipment and B to B cycle

Q. what is deference between lexical and bind parametors

Q. please explain about Transction types and Transction source?

Q. what are the differences between scm,distribution & financial modules?
what modules come under what, pls tell me?

Q. what is concurrent program

Q. I have developed a report and registered as a concurrent program having no errors .When i submit the program i want to get normal and error but not compiled or warning ?

Q. I M New Member of erp School why the Access of Uploading Article is not provided

Q. inventory interface in oracle apps with examples?

Q. HI

Q. Please give me detailed description about interfaces

Q. i want vendor conversion code for oracle apps

Q. i want vendor conversion code in oracle apps

Q. Hi,

What is the defination of Force View and when we rquired the force view?

Regards,
Venugopal.

Q. When i submit report as concurrent program i want to get answer as no data found ..which trigger shall i write for getting that answer?

Q. please provide me detail document for oracle alerts

Q. what is the step of conversion

Q. how to know wht r the colums requried for interface.

Q. What is Create Accounting?

Q. WHAT IS CONVERSION? WHAT IS THE DIFFERENT BETWEEN INTERFACE AND CONVERSION? PLS GIVE CLEARLY ONE EXAMPLE FOR CONVERSION?

Q. WHAT IS CONVERSION HOW IT IS DIFFERENT FROM INTERFACE? KINDLY GIVE 1 EXAMPLE FOR CONVERSION CLEARLY?

Q. what is the link between gl and ap

Q. while activity in soa bpel

Q. What is the diffrence between Accounting & Posting?

Q. o2c interview quetions

Q. What is the purpose to register a table in apps and how to register?

Q. first job

Q. can two users update the same row at the same time?if so how?

Q. i have a flat file with null values in different fields how to void null values

Q. please send creation of customization and personalization forms with screen shots throw manual

Q. what are po validations?

Q. master in law, {world economy}

Q. hi...how can we test a report(in PO or AP MODULE) before placing into production(any few common criteria we follow).....

Q. i want to add a field in AR form name of ARXRWMAI in find window

Q. how to use zoom in form personalization?

Q. How to do implement ZOOM Functionality using personalization?

Q. what are the mandatory fileds in order import program

Q. what are the mandatory columns for order import program,when you run order import program from legacy system?

Q. what is the usage of UTL FILE

Q. what is order management cycle explail brief

Q. what is order management cycle explail brief

Q. while creating XML reoprt,which one is mandatory either Data Definition or Template creation? and why?

Q. I am trying to cancel the PO using the po_document_control_pub API. But it will give error in case of Blanket PA, can anybody have the answer?

1 2 3 4 5 6 7 8 9
     

Unanswered Questions

Q. can any one tell me how to bring the KFF data into report parameters

Post answer

Q. i need a md50 for payroll element creation

Post answer

Q. with out purchage order we can pay payments?

Post answer

Q. i want some document abt oracle apps...and how to go in interface interfacetable to basetable...if u have interface document also please send to my id

Post answer

Q. how to get the item average cost or item material cost (average) through sql/ plsql script?

Post answer

Q. I booked one order how the remote user can find out his order because remote user doesn't know the our language. for which key column they find out ?

Post answer

Q. I developed rdf &generated XML report how the data has translated from xml data to our reporting styles(pdf,html,text....) ?

Post answer

Q. which column is key column between order management and invoice. ? how can i generate invoice for a particular order ?

Post answer

Q. I booked the order and shipped & I submit the work flow background program It shows invoice is generated But it is not generated where will it struck ? and in which table can i find out that invoice ?

Post answer

Q. Hi. I am very much new in this oracle erp. From my home I just trying to see the navigation paths of the inventory, while practicing in the solutionbeacon.com . Can anybody help me to start the inventory inputs. I wants to handle order management. But failed to understand that from where I can start.

Post answer

Q. WHAT ARE THE IMPORTANT BASE TABLES IN PO-MODULE

Post answer

Q. how to display complete calender in a sql code

Post answer

Q. overview of & small example of general ledger?

Post answer

Q. MANDATORY FIELDS FOR AP INTERFACE

Post answer

Q. what are all the runtime parameters for journal import

Post answer

Q. tell me difference between interface and conversion

Post answer

Q. If we have 100 operating units how can we change logo as per operating unit in XML Publisher?

Post answer

Q. can any one tell how to Customiz blanket purchase order agreement report

Post answer

Q. Please any one can tell about hrms payroll module(core) demo and steps.

Post answer

Q. Hi..in AP module user will enter supplier invoice information manually, this data will be already there in database. then wht is the need of getting the data from external system using AP inbound interface?

Post answer

Q.
APP-PER-50022:ORACLE HUMAN RESOUCES COULD NOT RETRIEVE A VALUE OF
THE USER TYPE PROFILE OPTION.
PLEASE ENSURE IT IS SET PROPERLY FOR YOUR RESPONSIBILITY...
how to retify the error can you give the navigation in po module

Post answer

Q. how to give link between requsisition and purchase order?

Post answer

Q. How to send the One flat file into multiple tables?
Please provide me the syntax also.

Post answer

Q. What is the Difference between special & pair valuesets?
Plz Provided me the Syntax also For those valuesets.

Post answer

Q. Hi all,

I want to display ap_invoices_interface table status='REJECTED' data we want display in log file

any one hlep please.its very urgent
we send my package and procedure also

CREATE OR REPLACE PACKAGE BODY APPS.xxiflic_ap_interface_pkg
AS
-- +===========================================================================+
-- | |
-- +===========================================================================+
-- | Name : XXIFLIC_AP_INTERFACE_PKG_BODY.sql |
-- | Project : AP Invoice Import Program |
-- | Application: |
-- | Inputs : |
-- | Outputs : |
-- | Database : |
-- | Description: |
-- | |
-- | |
-- | |
-- | |
-- | Related |
-- | Documents |
-- | |
-- |Version Date Author Comments |
-- |======= =========== ================= ================================= |
-- |1.0 Shashi Kumar Initial Version |
-- | |
-- +===========================================================================+

PROCEDURE ap_interface_proc(errbuf OUT VARCHAR2,retcode OUT VARCHAR2)
AS
--
-- Local Variable Declaration
--
ln_invoice_id_h NUMBER;
ln_invoice_id_l NUMBER;
ln_vendor_id po_vendors.vendor_id%TYPE;
ln_vendor_SITE_id po_vendor_SITES_all.vendor_SITE_id%TYPE;
ln_terms_id ap_terms.term_id%TYPE;
lc_terms_name ap_terms.name%TYPE;
lc_error_flag CHAR(1) := 'N';
ld_invoice_date VARCHAR2(25);--ap_invoices_all.invoice_date%Type;
ld_gl_date VARCHAR2(25);--ap_invoices_all.gl_date%Type;
lc_vendor_name po_vendors.vendor_name%TYPE;
lc_vendor_num po_vendors.segment1%TYPE;
lc_vendor_SITE_code po_vendor_SITES_all.VENDOR_SITE_CODE%TYPE;
lc_INVOICE_CURRENCY_CODE ap_invoices_all.INVOICE_CURRENCY_CODE%TYPE;
lc_exchange_rate VARCHAR2(50);--ap_invoices_all.exchange_rate%Type;
ln_code_combination_id NUMBER;
ln_ou NUMBER;
ln_set_of_books_id NUMBER;
ln_laibility_ccid NUMBER;
ln_invoice_amount NUMBER :=0;
lc_exchange_rate_type VARCHAR2(25);
LC_DESCRIPTION VARCHAR2(240);
lc_DIST_CODE_CONCATENATED VARCHAR2(60);
lc_prepayment_account VARCHAR2(60);
lc_attribute15 VARCHAR2(50);
lc_attribute15_ccid NUMBER :=0;
ln_inv_count NUMBER := 0;
ln_rej_count NUMBER := 0; --Added by Rambhupal
ln_line_count NUMBER := 0;
lc_err_msg VARCHAR2(3000);
LN_RECD_COUNT NUMBER := 0;
LN_PREPAY_AMT_1 NUMBER := 0;
LN_PREPAY_AMT_2 NUMBER := 0;
LN_PRE_APP_AMT NUMBER := 0;
LN_COA_ID NUMBER := 0;
LN_CCD_ID NUMBER := 0;
ln_line_amt NUMBER := 0;
ln_invoice_amt NUMBER;
l_PREPAY_DIST_NUM VARCHAR2(50):= NULL; ---to be fetched
l_LINE_TYPE_LOOKUP_CODE VARCHAR2(250):= NULL;---to be fetched
lv_inv_lukup varchar2(30);
ln_vendor_check NUMBER;
ln_orig_site_id NUMBER;
ln_vendor_site_check NUMBER;

--
-- Invoice Header Information getting
--
CURSOR c_header_inf
IS
SELECT DISTINCT INVOICE_NUMBER,SITE_ID,INVOICE_AMOUNT,gl_date
,INVOICE_DATE,INVOICE_TYPE,ORG_ID,voucher_number
,PREPAY_NUM,PREPAY_APPLY_AMOUNT,INVOICE_INCLUDES_PREPAY_FLAG,prepay_gl_date,PAY_GROUP_LOOKUP_CODE,
PAYMENT_METHOD_LOOKUP_CODE
FROM XXIFLIC_AP_INVOICE_STAGING
WHERE interface_status IS NULL;
-- Invoice Lines Information getting
--
CURSOR c_lines_inf(p_INVOICE_NUM VARCHAR2,p_VENDOR_SITE_ID NUMBER)
IS
SELECT DISTINCT *
FROM XXIFLIC_AP_INVOICE_STAGING
WHERE INVOICE_NUMBER = p_INVOICE_NUM
AND SITE_ID = p_VENDOR_SITE_ID
AND interface_status IS NULL;


--
BEGIN

delete from XXIFLIC_AP_INVOICE_STAGING
WHERE NVL(interface_status,'N') = 'E';
--

--
COMMIT;
--


BEGIN
------SOURCE SYSTEM 1 TnE_BusinessBilling_v@DG4ODBC -----------------------

insert into XXIFLIC_AP_INVOICE_STAGING(invoice_number
,invoice_type
,invoice_date
,site_id
,invoice_amount
,invoice_currency
,terms_name
,invoice_description
,payment_method_lookup_code
,pay_group_lookup_code
,gl_date
,org_id
,line_number
,line_type_lookup_code
,amount
,accounting_date
,line_description
,dist_code_concatenated
,voucher_number
,employee_number
,accounting_entry_id
,module_id
)
(select invoice_number,invoice_type,invoice_date,supplier_site,total_os_inv_amount,invoice_currency,payment_terms,invoice_header_description,payment_method,null,sysdate,83
,null,line_type,os_inv_line_amount,null,description,nvl(expense_account,prepayment_account),voucher_no,null,accounting_entry_id,module_id
from TnE_BusinessBilling_v@DG4ODBC xxtne
where accounting_entry_id not in (select accounting_entry_id from XXIFLIC_AP_INVOICE_STAGING xxai where xxai.module_id = xxtne.module_id));
--
commit;
--
------SOURCE SYSTEM 2 TnE_BusinessReimbursement_v@DG4ODBC -----------------------

insert into XXIFLIC_AP_INVOICE_STAGING(invoice_number
,invoice_type
,invoice_date
,site_id
,invoice_amount
,invoice_currency
,terms_name
,invoice_description
,payment_method_lookup_code
,pay_group_lookup_code
,gl_date
,org_id
,line_number
,line_type_lookup_code
,amount
,accounting_date
,line_description
,dist_code_concatenated
,voucher_number
,employee_number
,accounting_entry_id
,module_id
)
(select invoice_number,invoice_type,invoice_date,supplier_site,total_os_inv_amount,invoice_currency,payment_terms,invoice_header_description,payment_method,null,sysdate,83
,null,line_type,os_inv_line_amount,null,description,nvl(expense_account,prepayment_account),voucher_no,null,accounting_entry_id,module_id
from TnE_BusinessReimbursement_v@DG4ODBC xxtne
where accounting_entry_id not in (select accounting_entry_id from XXIFLIC_AP_INVOICE_STAGING xxai where xxai.module_id = xxtne.module_id));
--
COMMIT;
------SOURCE SYSTEM 3 TnE_VendorAdvance_v@DG4ODBC -----------------------

insert into XXIFLIC_AP_INVOICE_STAGING(invoice_number
,invoice_type
,invoice_date
,site_id
,invoice_amount
,invoice_currency
,terms_name
,invoice_description
,payment_method_lookup_code
,pay_group_lookup_code
,gl_date
,org_id
,line_number
,line_type_lookup_code
,amount
,accounting_date
,line_description
,dist_code_concatenated
,voucher_number
,employee_number
,accounting_entry_id
,module_id
)
(select invoice_number,invoice_type,invoice_date,supplier_site,total_os_inv_amount,invoice_currency,payment_terms,invoice_header_description,payment_method,null,sysdate,83
,null,line_type,os_inv_line_amount,null,description,nvl(expense_account,prepayment_account),voucher_no,null,accounting_entry_id,module_id
from TnE_VendorAdvance_v@DG4ODBC xxtne
where accounting_entry_id not in (select accounting_entry_id from XXIFLIC_AP_INVOICE_STAGING xxai where xxai.module_id = xxtne.module_id));
--
COMMIT;
------SOURCE SYSTEM 4 TnE_VendorInvoice_v@DG4ODBC -----------------------

insert into XXIFLIC_AP_INVOICE_STAGING(invoice_number
,invoice_type
,invoice_date
,site_id
,invoice_amount
,invoice_currency
,terms_name
,invoice_description
,payment_method_lookup_code
,pay_group_lookup_code
,gl_date
,org_id
,line_number
,line_type_lookup_code
,amount
,accounting_date
,line_description
,dist_code_concatenated
,voucher_number
,employee_number
,accounting_entry_id
,module_id
)
(select invoice_number,invoice_type,invoice_date,supplier_site,total_os_inv_amount,invoice_currency,payment_terms,invoice_header_description,payment_method,null,sysdate,83
,null,line_type,os_inv_line_amount,null,description,nvl(expense_account,prepayment_account),voucher_no,null,accounting_entry_id,module_id
from TnE_VendorInvoice_v@DG4ODBC xxtne
where accounting_entry_id not in (select accounting_entry_id from XXIFLIC_AP_INVOICE_STAGING xxai where xxai.module_id = xxtne.module_id));
--
COMMIT;
------SOURCE SYSTEM 5 TnE_VendorRegbilling_v@DG4ODBC -----------------------

insert into XXIFLIC_AP_INVOICE_STAGING(invoice_number
,invoice_type
,invoice_date
,site_id
,invoice_amount
,invoice_currency
,terms_name
,invoice_description
,payment_method_lookup_code
,pay_group_lookup_code
,gl_date
,org_id
,line_number
,line_type_lookup_code
,amount
,accounting_date
,line_description
,dist_code_concatenated
,voucher_number
,employee_number
,accounting_entry_id
,module_id
)
(select invoice_number,invoice_type,invoice_date,supplier_site,total_os_inv_amount,invoice_currency,payment_terms,invoice_header_description,payment_method,null,sysdate,83
,null,line_type,os_inv_line_amount,null,description,nvl(expense_account,prepayment_account),voucher_no,null,accounting_entry_id,module_id
from TnE_VendorRegbilling_v@DG4ODBC xxtne
where accounting_entry_id not in (select accounting_entry_id from XXIFLIC_AP_INVOICE_STAGING xxai where xxai.module_id = xxtne.module_id));
--
COMMIT;
exception
WHEN OTHERS THEN
lc_err_msg := 'EXCEPTION while inserting data into staging'||SQLERRM;
END;
------------
--
-- Updating Interface status flag message to NULL
--


FOR i IN c_header_inf
LOOP
--
-- Initializations
--
lc_error_flag := 'N';
lc_err_msg := NULL;
ln_invoice_amt := i.invoice_amount;
ln_vendor_site_check := 0;
--
-- Invoice Id fetching
--
SELECT ap_invoices_interface_s.NEXTVAL
INTO ln_invoice_id_h
FROM dual;
--
--
IF i.invoice_number is null then
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Invoice Number Can not be Null,';
END IF;
--
IF i.site_id is null then
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'site id Can not be Null,';
END IF;

BEGIN
SELECT lookup_code
INTO lv_inv_lukup
FROM FND_LOOKUP_VALUES_VL
WHERE LOOKUP_TYPE LIKE 'INVOICE TYPE'
AND lookup_code = decode(trim(i.INVOICE_TYPE),'Standard Invoice','STANDARD',upper(i.INVOICE_TYPE));
EXCEPTION
when others then
lv_inv_lukup := NULL;
END;
IF lv_inv_lukup IS NULL THEN
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Invalid Invoice_type not be Null,';
END IF;
--
lv_inv_lukup := NULL;

BEGIN
SELECT lookup_code
INTO lv_inv_lukup
FROM FND_LOOKUP_VALUES_VL
WHERE LOOKUP_TYPE LIKE 'PAYMENT METHOD'
AND lookup_code = i.PAYMENT_METHOD_LOOKUP_CODE;
EXCEPTION
when others then
lv_inv_lukup := NULL;
END;

IF lv_inv_lukup IS NULL THEN
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Invalid payment method lookup code not be Null,';
END IF;
--


-- Org Id validation

IF i.org_id is null then
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Org Id Can not be Null,';
ELSE
BEGIN
SELECT organization_id
INTO ln_ou
FROM hr_operating_units
where organization_id = i.org_id;
exception
when others then
ln_ou := 0;
END;
--
IF (ln_ou = 0) OR (ln_ou is NULL) then
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Invalid Organization Id,';
END IF;
END IF;
--

--
-- Invoice Date fetching
--
IF lc_error_flag <> 'Y' THEN
BEGIN
SELECT distinct
invoice_date
,gl_date
,INVOICE_CURRENCY
,INVOICE_description
-- ,DIST_CODE_CONCATENATED
INTO ld_invoice_date
,ld_gl_date
,lc_INVOICE_CURRENCY_CODE
,lc_description
--,lc_DIST_CODE_CONCATENATED
FROM XXIFLIC_AP_INVOICE_STAGING
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
AND INTERFACE_STATUS IS NULL;
EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Invoice Data is Inconsistent'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
lc_error_flag := 'Y';
--
lc_err_msg := lc_err_msg||' Invoice Data is Inconsistent,';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Error while fetching invoice data'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;

lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while fetching invoice data,';
END;
ELSE
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||lc_err_msg
WHERE NVL(SITE_ID,1) = NVL(i.SITE_ID,1)
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
commit;
END IF;
--
-- Vendor Id fetching
--
-----Site Id Check ----------
ln_vendor_check := 0;
ln_orig_site_id := 0;
--
BEGIN
SELECT PVS.vendor_site_id
INTO ln_vendor_check
FROM PO_VENDOR_SITES_ALL PVS
WHERE PVS.vendor_site_id = i.SITE_ID;
EXCEPTION
WHEN OTHERS THEN
ln_vendor_check := 0;
END;
--
IF ln_vendor_check = 0 THEN
--
ln_vendor_site_check:=0;
BEGIN
SELECT PVS.vendor_site_id
INTO ln_vendor_site_check
FROM PO_VENDORS PV
,PO_VENDOR_SITES_ALL PVS
WHERE PV.vendor_id = pvs.vendor_id
and pvs.vendor_site_code = 'OFFICE'
and pv.segment1 = to_char(i.SITE_ID)
and pvs.org_id = i.org_id;
EXCEPTION
WHEN OTHERS THEN
ln_vendor_site_check := 0;
END;
--
IF ln_vendor_site_check = 0 THEN
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Vendor not exists,';
ELSE
ln_orig_site_id := i.SITE_ID;
i.SITE_ID := ln_vendor_site_check;
END IF;
END IF;
--
IF lc_error_flag <> 'Y' THEN
BEGIN
SELECT pv.vendor_id
,pv.vendor_name
,segment1 vendor_num
INTO ln_vendor_id
,lc_vendor_name
,lc_vendor_num
FROM po_vendors PV
,po_vendor_sites_all povsa
WHERE pv.vendor_id = povsa.vendor_id
and povsa.vendor_site_id = i.site_id
and povsa.org_id = i.org_id;

EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Vendor not exists.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Vendor not exists,';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Error while fetching Vendor Id.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while fetching Vendor Id,';
END;
END IF;
--

--
-- Vendor VENDOR_SITE_CODE Id fetching
--
IF lc_error_flag <> 'Y' THEN
BEGIN
SELECT POVSA.vendor_SITE_ID
,POVSA.vendor_SITE_CODE
INTO ln_vendor_SITE_id
,lc_vendor_SITE_code
FROM po_vendor_SITEs_all POVSA
, po_vendors PV
WHERE pv.vendor_id = povsa.vendor_id
and povsa.vendor_site_id = i.site_id
and povsa.org_id = i.org_id;
EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Vendor VENDOR_SITE_ID not exists.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Vendor VENDOR_SITE_IDnot exists,';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Error while fetching Vendor VENDOR_SITE_ID.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while fetching Vendor VENDOR_SITE_ID,';
END;
END IF;
--
IF ln_vendor_site_check <> 0 THEN

i.SITE_ID := ln_orig_site_id;
END IF;
--
-- Term Id fetching
--
IF lc_error_flag <> 'Y' THEN
BEGIN
SELECT pvsa.terms_id
,apt.name
INTO ln_terms_id
,lc_terms_name
FROM po_vendor_SITEs_all PVSA
, ap_terms apt
WHERE PVSA.vendor_SITE_ID = i.SITE_ID
AND pvsa.terms_id = apt.term_id
AND org_id = ln_ou;
EXCEPTION
WHEN OTHERS THEN
ln_terms_id := NULL;
lc_err_msg := lc_err_msg||NULL;--' Error while fetching term id,';
END;
END IF;

IF lc_error_flag <> 'Y' THEN
ln_invoice_amount := 0;
ln_inv_count := ln_inv_count+1;

ln_rej_count := ln_rej_count+1; --Added by Srinivas
--
-- Inserting into AP_INVOICES_INTERFACE Table
--
IF NVL(lc_INVOICE_CURRENCY_CODE,'INR') = 'INR' THEN
ln_invoice_amount := i.invoice_amount;
lc_exchange_rate_type := NULL;
ELSE
ln_invoice_amount := NVL(i.invoice_amount,0);
lc_exchange_rate_type := 'User';
END IF;
BEGIN
INSERT INTO ap_invoices_interface(
invoice_id,
invoice_num,
INVOICE_TYPE_LOOKUP_CODE,
invoice_date,
po_number,
vendor_id,
vendor_num,
--vendor_name,
vendor_SITE_id,
vendor_SITE_code,
invoice_amount,
INVOICE_CURRENCY_CODE,
exchange_rate,
exchange_rate_type,
exchange_date,
terms_id,
terms_name,
description,
last_update_date,
last_updated_by,
last_update_login,
creation_date,
created_by,
source,
group_id,
gl_date,
--accts_pay_code_combination_id,
org_id,
DOC_CATEGORY_CODE,
--attribute15
PREPAY_NUM
,PREPAY_APPLY_AMOUNT
,INVOICE_INCLUDES_PREPAY_FLAG
,PREPAY_GL_DATE
,pay_group_lookup_code
,PREPAY_DIST_NUM
,attribute_category
,attribute1
-- ,attribute2
-- ,attribute3
-- ,attribute4
-- ,attribute5
,PAYMENT_METHOD_LOOKUP_CODE

) VALUES (
ln_invoice_id_h, -- invoice_id
i.INVOICE_NUMBER, -- invoice_num
decode(trim(i.INVOICE_TYPE),'Standard Invoice','STANDARD',upper(i.INVOICE_TYPE)), -- INVOICE_TYPE_LOOKUP_CODE_LOOKUP_CODE_LOOKUP_CODE_lookup_code
ld_invoice_date, -- invoice_date
NULL, -- po_number
ln_vendor_id, -- vendor_id
lc_vendor_num, -- vendor_num
--lc_vendor_name, -- vendor_name
ln_vendor_SITE_id, -- vendor_VENDOR_SITE_CODE_id
lc_vendor_SITE_code, -- vendor_VENDOR_SITE_CODE_code
ln_invoice_amount, -- invoice_amount
lc_INVOICE_CURRENCY_CODE, -- INVOICE_CURRENCY_CODE_code
lc_exchange_rate, -- exchange_rate
lc_exchange_rate_type, -- exchange_rate_type
NULL, -- exchange_date
NVL(ln_terms_id,10000), -- terms_id
lc_terms_name, -- terms_name
NVL(lc_description,NULL),-- description
SYSDATE, -- last_update_date
FND_GLOBAL.USER_ID, -- last_updated_by
FND_GLOBAL.USER_ID, -- last_update_login
SYSDATE, -- creation_date
FND_GLOBAL.USER_ID, -- created_by
'MIGRATION',--'MIGRATION_PAYABLE', -- source
NULL, -- group_id
i.gl_date,--gl_date
--ln_laibility_ccid, -- accts_pay_code_combination_id
NVL(i.ORG_ID,FND_GLOBAL.ORG_ID), -- org_id
decode(decode(trim(i.INVOICE_TYPE),'Standard Invoice','STANDARD',upper(i.INVOICE_TYPE)),'STANDARD','STD INV','PREPAYMENT','PREPAY INV','CREDIT','CRM INV','DBM INV'),
--lc_attribute15_ccid
i.prepay_num
,i.PREPAY_APPLY_AMOUNT
,i.INVOICE_INCLUDES_PREPAY_FLAG
,i.prepay_gl_date
,i.PAY_GROUP_LOOKUP_CODE
,l_PREPAY_DIST_NUM
,decode(i.VOUCHER_NUMBER,NULL,NULL,'Vendor Invoice Details')
,i.VOUCHER_NUMBER
--,i.attribute2
--,i.attribute3
--,i.attribute4
--,i.attribute5
,i.PAYMENT_METHOD_LOOKUP_CODE
);
EXCEPTION
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Error while inserting into AP_INVOICES_INTERFACE.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;

lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while inserting into AP_INVOICES_INTERFACE,'||SQLERRM||'- '||ln_invoice_id_h;
END;
END IF;
--
-- Lines data inserting into ap_invoice_lines_interface
--
FOR j IN c_lines_inf(i.INVOICE_NUMBER,i.SITE_ID)
LOOP
--
-- Invoice Line Id fetching
--
IF lc_error_flag <> 'Y' THEN
--
lv_inv_lukup := NULL;

BEGIN
SELECT lookup_code
INTO lv_inv_lukup
FROM FND_LOOKUP_VALUES_VL
WHERE LOOKUP_TYPE LIKE 'INVOICE LINE TYPE'
AND lookup_code = upper(trim(j.line_type_lookup_code));
EXCEPTION
when others then
lv_inv_lukup := NULL;
END;

IF lv_inv_lukup IS NULL THEN
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Invalid Line Type lookup code not be Null,';
END IF;

BEGIN
SELECT gll.chart_of_accounts_id
INTO LN_COA_ID
FROM hr_operating_units hou
,gl_ledgers gll
WHERE hou.set_of_books_id = gll.ledger_id
AND hou.organization_id = i.ORG_ID;
EXCEPTION
WHEN OTHERS THEN
LN_COA_ID := NULL;
END;
--
BEGIN
SELECT fnd_flex_ext.get_ccid('SQLGL',
'GL#',
NVL(LN_COA_ID,50348),
fnd_date.date_to_canonical(SYSDATE),
j.DIST_CODE_CONCATENATED
)
INTO LN_CCD_ID
FROM DUAL;
-- COMMIT;
EXCEPTION
WHEN OTHERS THEN
LN_CCD_ID := NULL;
END;
--
IF LN_CCD_ID = 0 THEN
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Code Combination is Invalid,';
END IF;
--
IF i.INVOICE_TYPE = 'STANDARD' THEN
BEGIN
SELECT code_combination_id
INTO ln_code_combination_id
FROM gl_code_combinations_kfv
WHERE concatenated_segments = j.DIST_CODE_CONCATENATED;
EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'STANDARD Combination Id not exists'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
AND DIST_CODE_CONCATENATED = j.DIST_CODE_CONCATENATED;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Code Combination ID not Exist,';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'Error while fetching STANDARD Combination.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
AND DIST_CODE_CONCATENATED = j.DIST_CODE_CONCATENATED;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while fetching STANDARD Combination,';
END;
/*
ELSIF i.INVOICE_TYPE_LOOKUP_CODE = 'PREPAYMENT' THEN
BEGIN
SELECT code_combination_id
INTO ln_code_combination_id
FROM gl_code_combinations_kfv
WHERE concatenated_segments = lc_prepayment_account;
EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'PREPAYMENT Combination Id not exists'
WHERE VENDOR_NAME = i.VENDOR_NAME
AND INVOICE_NUM = i.INVOICE_NUM
AND VENDOR_SITE_CODE = i.VENDOR_SITE_CODE;
lc_error_flag := 'Y';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'PREPAYMENT Error while fetching Combination.'
WHERE VENDOR_NAME = i.VENDOR_NAME
AND INVOICE_NUM = i.INVOICE_NUM
AND VENDOR_SITE_CODE = i.VENDOR_SITE_CODE;
lc_error_flag := 'Y';
END;
*/
ELSE
BEGIN
SELECT code_combination_id
INTO ln_code_combination_id
FROM gl_code_combinations_kfv
WHERE concatenated_segments = j.DIST_CODE_CONCATENATED;
EXCEPTION
WHEN NO_DATA_FOUND THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'CREDIT Combination Id not exists'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
AND DIST_CODE_CONCATENATED = j.DIST_CODE_CONCATENATED;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Code Combination ID not Exist,';
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = 'Error while fetching CREDIT Combination.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
AND DIST_CODE_CONCATENATED = j.DIST_CODE_CONCATENATED;
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' Error while fetching code Combination,';
END;
END IF;
END IF;
--
IF lc_error_flag <> 'Y' THEN
--ln_line_count := ln_line_count+1;
--
SELECT ap_invoice_lines_interface_s.NEXTVAL
INTO ln_invoice_id_l
FROM dual;
BEGIN
INSERT INTO ap_invoice_lines_interface(
INVOice_id,
invoice_line_id,
line_number,
line_type_lookup_code,
line_group_number,
amount,
dist_code_combination_id,
last_updated_by,
last_update_date,
last_update_login,
created_by,
creation_date,
org_id,
description,
--ATTRIBUTE_CATEGORY,
ATTRIBUTE1
)
VALUES (
ln_invoice_id_h, -- INVOICE_ID
ln_invoice_id_l, -- INVOICE_LINE_ID
j.line_number, -- LINE_NUMBER
NVL(upper(trim(j.line_type_lookup_code)),'ITEM'), -- LINE_TYPE_LOOKUP_CODE
NULL, -- LINE_GROUP_NUMBER
--j.invoice_amount, -- AMOUNT
NVL(j.amount,ln_invoice_amount),
ln_code_combination_id,--DIST_CODE_COMBINATION_ID
FND_GLOBAL.USER_ID, -- last_updated_by
SYSDATE, -- last_update_date
FND_GLOBAL.USER_ID, -- last_update_login
FND_GLOBAL.USER_ID, -- created_by
SYSDATE, -- creation_date
NVL(j.org_id,FND_GLOBAL.ORG_ID), -- ORG_ID
NVL(j.line_description,'Migration Invoice'),
--J.DIST_ATTRIBUTE_CATEGORY,
J.EMPLOYEE_NUMBER
);
EXCEPTION
WHEN OTHERS THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E',
error_message = error_message||'Error while inserting into AP_INVOICE_LINES_INTERFACE.'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id
and nvl(line_number,1) = nvl(j.line_number,1);
--
-- Deleting header inf beacuse while inserting in lines data i m getting error
--
--DELETE FROM AP_INVOICES_INTERFACE WHERE invoice_id = ln_invoice_id_h;

lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||'Error while inserting into AP_INVOICE_LINES_INTERFACE,'||SQLERRM;
END;

END IF;
END LOOP;--c_lines_inf
--
--
-- FND_FILE.PUT_LINE(FND_FILE.OUTPUT,'Inserted '||'- '||ln_line_count||' LINES OF INVOICE NUMBER '||i.INVOICE_NUM);
--
-- Update interface_status = P in ur staging table after inserting
-- into AP Invoices Interface table
--
ln_line_count := 0;
--
----check for unbalance Invoice Lines ------------

BEGIN
SELECT SUM(amount)
INTO ln_line_amt
FROM XXIFLIC_AP_INVOICE_STAGING
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
--AND (INTERFACE_STATUS <> 'E' or (INTERFACE_STATUS is NULL));
EXCEPTION
WHEN OTHERS THEN
ln_line_amt := 0;
END;
--
IF ln_line_amt <> ln_invoice_amt THEN
rollback;

UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'E'
,error_message = error_message||'Unbalnced Invoice Lines'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
--
lc_error_flag := 'Y';
lc_err_msg := lc_err_msg||' ,Unbalnced Invoice Lines' ;
COMMIT;
END IF;
--
IF lc_error_flag <> 'Y'
THEN
UPDATE XXIFLIC_AP_INVOICE_STAGING
SET interface_status = 'P'
WHERE SITE_ID = i.SITE_ID
AND INVOICE_NUMBER = i.INVOICE_NUMBER
AND org_id = i.org_id;
COMMIT;
ELSE

FND_FILE.PUT_LINE(FND_FILE.LOG,'Voucher Number - '||i.VOUCHER_NUMBER||' - '||lc_err_msg);
END IF;
-- Invoice and Line count --
END LOOP;--c_headers_inf
--

--
BEGIN
SELECT COUNT(*)
INTO ln_inv_count
FROM AP_INVOICES_INTERFACE aii
,ap_invoice_lines_interface ail
WHERE aii.invoice_id = ail.invoice_id
AND aii.SOURCE = 'MIGRATION'
AND aii.STATUS IS NULL;
EXCEPTION
WHEN OTHERS THEN
ln_inv_count := 0;
END;
--
DELETE FROM AP_INVOICES_INTERFACE
WHERE SOURCE = 'MIGRATION'
AND INVOICE_ID NOT IN (SELECT INVOICE_ID FROM AP_INVOICE_LINES_INTERFACE);
commit;
FND_FILE.PUT_LINE(FND_FILE.OUTPUT,'Total Invoice lines loaded'||' - '||ln_inv_count);
END ap_interface_proc;
END xxiflic_ap_interface_pkg;
/





Post answer

Q. how to give link between requisition and purchase order?

Post answer

Q. hi all
pls help me on interfaces how can validate the rejection records in interfaces?
pls guide me thanks in advances......

Post answer

Q. hi i have question about oracle reports.
How many layouts can create in layout model?
how can create multiple layouts in single layout model?
please guide me?
thanks in advance........

Post answer

Q. I am trying to get multiple Projects and Job Events from the same Client to show up on one invoice.

Example:
For Client MM I have set up Project "A". Under Project "A" I have Job Events 1,2, and 3.
Also under Client MM I have set up Project "B". Under Project "B" I have Job Events 1,2, and 3.

I want both Project "A"s Job Events and Project "B"s Job Events to print on one invoice.

Right now I have to print Project "A"s Events. Then print Project "B"s Events on a separate invoice.

Hope this makes sense. Thanks in advance.

Post answer

Q. could you please provide me brief explanation about order management and inventory modules

Post answer

Q. I am trying to get multiple Projects and Job Events from the same Client to show up on one invoice.

Example:
For Client Joe Smith I have set up Project "A". Under Project "A" I have Job Events 1,2, and 3.
Also under Client Joe Smith I have set up Project "B". Under Project "B" I have Job Events 1,2, and 3.

I want both Project "A"s Job Events and Project "B"s Job Events to print on one invoice.

Right now I have to print Project "A"s Events. Then print Project "B"s Events on a separate invoice.

Hope this makes sense. Thanks in advance.

Post answer

Q. Can we group multi projects to one invoice for same customer. Client has Oracle Billing, Oracle Costing, Receivables etc.

This is very urgent any suggestion or help please.

Thanks a million in advance.

Post answer

Q. How to disable the invoice batch

Post answer

Q. In which table deferred PO number stored or any query for to get the deferred list.

Post answer

Q. Explain about External tables

Post answer

Q. how to create a new api in oracle apps

Post answer

Q. What is AutoAccounting?

Post answer

Q. what is the difference between bitmap index and binary index ?

Post answer

Q. How many minimum fields are require to develop the Matrix, Matrix with Group Reports?

Post answer

Q. i want full functioning of oracle apps imlementation give me tutorials

Post answer
1