My Oracle Support Banner

R12: AP: Error When creating taxes for a PO Matched Invoice “ORA-20001: APPSQLAP-10000: ORA-01400: cannot insert NULL into ("AP", "AP_INVOICE_DISTRIBUTIONS_ALL", "DIST_CODE_COMBINATION_ ID") occurred in Insert_Tax_Distributions” In Detail Tax Lines Form (Doc ID 3061924.1)

Last updated on JANUARY 24, 2025

Applies to:

Oracle Payables - Version 12.2.5 and later
Information in this document applies to any platform.

Symptoms

When attempting to validate a PO matched invoice, the following errors messages occur in the Detail Tax Lines form from Invoice Workbench:

Error
------------------------------------------------------------------------------------------------------
APP-SQLAP-10000: ORA-01400: cannot insert NULL into
("AP", "AP_INVOICE_DISTRIBUTIONS_ALL", "DIST_CODE_COMBINATION_ID") occurred in
Insert_Tax_Distributions <- 
AP_ETAX_UTILITY_PKG.Return_Tax_Distributions<-AP_ETAX_SERVICES_PKG.Update_AP<-
AP_ETAX_SERVICES_PKG.Distribute<-AP_ETAX_PKG.Calling_eTax<-
AP_APPROVAL_PKG.Override_Tax<-AP_ETAX_PKG.Calling_eTax
apxinwkb_etax_utils.override_tax_lines_dists
with parameters ( P_Invoice_Id = &invoice_id P_Calling_Sequence =
AP_ETAX_UTILITY_PKG.Return_Tax_Distributions<-AP_ETAX_SERVICES_PKG.Update_AP<-
AP_ETAX_SERVICES_PKG.Distribute<-AP_ETAX_PKG.Calling_eTax
apxinwkb_etax_utils.override_tax_lines_dists)
while performing the following operation:
Step 11: Insert new distributions including variances

 

The FND Debug Log shows these error messages:

MODULE LOG_SEQUENCE LOG_LEVEL MESSAGE_TEXT
AP.PLSQL.AP_ETAX_SERVICES_PKG.Populate_headers_gt  1 Application_id: 200
AP.PLSQL.AP_ETAX_SERVICES_PKG.Populate_headers_gt  1 Entity_code: AP_INVOICES
AP.PLSQL.AP_ETAX_SERVICES_PKG.Populate_headers_gt  1 event_class_code: STANDARD INVOICES
AP.PLSQL.AP_ETAX_SERVICES_PKG.Populate_headers_gt  1 event_type_code: STANDARD UPDATED
AP.PLSQL.AP_ETAX_SERVICES_PKG.Populate_headers_gt  1 Invoice_id: &invoice_id
xla.plsql.xla_events_pkg.event_exists  2 BEGIN of procedure event_exists
xla.plsql.xla_events_pkg.event_exists  2 source_application_id =
xla.plsql.xla_events_pkg.event_exists  2 application_id = 200
xla.plsql.xla_events_pkg.event_exists  2 legal_entity_id = &legal_entity_id
xla.plsql.xla_events_pkg.event_exists  2 ledger_id = &ledger_id
xla.plsql.xla_events_pkg.event_exists  2 entity_type_code = AP_INVOICES
xla.plsql.xla_events_pkg.event_exists  2 transaction_number = &invoice_num
xla.plsql.xla_events_pkg.event_exists  2 source_id_int_1 = &invoice_id
ZX.PLSQL.ZX_API_PUB.DETERMINE_RECOVERY  1 application_id: 200 entity_code: AP_INVOICES event_class_code: STANDARD INVOICES event_type_code: STANDARD REDISTRIBUTE trx_id: &invoice_id internal_organization_id: &org_id quote_flag: N icx_session_id:
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID From Cursor 4790441
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Get CCID For LCM Enanbled Transaction
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 LCM Enabled Y
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 RCV Transaction Id 47271025
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID For LCM Enanbled Transaction 4790441
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Insert Tax Variance Distributions
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  2 AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions(+)
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  1 Step 11: Insert new distributions including variances
AP.PLSQL.AP_ETAX_UTILITY_PKG.TAX_ONLY_LINE_EXIST  1 Checking if there is tax only line exists
AP.PLSQL.AP_ETAX_UTILITY_PKG.TAX_ONLY_LINE_EXIST  1 in others: No Tax Only Line
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  2 AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions(-)
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID From Cursor 4790441
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Get CCID For LCM Enanbled Transaction
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 LCM Enabled Y
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 RCV Transaction Id 47271027
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID For LCM Enanbled Transaction 4790441
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Insert Tax Variance Distributions
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  2 AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions(+)
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  1 Step 11: Insert new distributions including variances
AP.PLSQL.AP_ETAX_UTILITY_PKG.TAX_ONLY_LINE_EXIST  1 Checking if there is tax only line exists
AP.PLSQL.AP_ETAX_UTILITY_PKG.TAX_ONLY_LINE_EXIST  1 in others: No Tax Only Line
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  2 AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions(-)
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID From Cursor 1560
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Get CCID For LCM Enanbled Transaction
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 LCM Enabled Y
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 RCV Transaction Id 47271001
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 CCID For LCM Enanbled Transaction
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  1 Insert Tax Variance Distributions
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  2 AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions(+)
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  1 Step 11: Insert new distributions including variances
AP.PLSQL.AP_ETAX_UTILITY_PKG.Insert_Tax_Distributions  4 ORA-01400: cannot insert NULL into ("AP"."AP_INVOICE_DISTRIBUTIONS_ALL"."DIST_CODE_COMBINATION_ID")
fnd.plsql.APP_EXCEPTION.RAISE_EXCEPTION.dict_auto_log  4 "APP-SQLAP-10000: ORA-01400: cannot insert NULL into (""AP"".""AP_INVOICE_DISTRIBUTIONS_ALL"".""DIST_CODE_COMBINATION_ID"") occurred in
Insert_Tax_Distributions <- AP_ETAX_UTILITY_PKG.Return_Tax_Distributions<-AP_ETAX_SERVICES_PKG.Update_AP<-AP_ETAX_SERVICES_PKG.Distribute<-AP_ETAX_PKG.Calling_eTax<-AP_ETAX_SERVICES_PKG.Override_Tax<-AP_ETAX_PKG.Calling_eTax<-APXINWKB -> apxinwkb_etax_utils.override_tax_lines_dists
with parameters ( P_Invoice_Id = &invoice_id P_Calling_Sequence = AP_ETAX_UTILITY_PKG.Return_Tax_Distributions<-AP_ETAX_SERVICES_PKG.Update_AP<-AP_ETAX_SERVICES_PKG.Distribute<-AP_ETAX_PKG.Calling_eTax<-AP_ETAX_SERVICES_PKG.Override_Tax<-AP_ETAX_PKG.Calling_eTax<-APXINWKB -> apxinwkb_etax_utils.override_tax_lines_dists)
while performing the following operation:
Step 11: Insert new distributions including variances"
AP.PLSQL.AP_ETAX_UTILITY_PKG.RETURN_TAX_DISTRIBUTIONS  4 "ORA-20001: APP-SQLAP-10000: ORA-01400: cannot insert NULL into (""AP"".""AP_INVOICE_DISTRIBUTIONS_ALL"".""DIST_CODE_COMBINATION_ID"") occurred in
Insert_Tax_Distributions <- AP_ETAX_UTILITY_PKG.Return_Tax_Distributions<-AP_ETAX_SERVICES_PKG.Update_AP<-AP_ETAX_SERVICES_PKG.Distribute<-AP_ETAX_PKG.Calling_eTax<-AP_ETAX_SERVICES_PKG.Override_Tax<-AP_ETAX_PKG.Calling_eTax<-APXINWKB -> apxinwkb_etax_utils.override_tax_lines_dists

 
The issue can be reproduced at will with the following steps:

  1. Go to Payables responsibility
    Invoices - Entry - Invoices
  2. Enter/Query an invoice that is matched to Purchase Order
  3. Click on <Tax Details> button

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.