BalanceForwardReceipts

Balance Forward Receipts

Minor Business Rule

Object Name: B03B0030

Parent DLL: CFIN

Location: Client/Server

Language: C

Functional Description  B03B0030

Purpose


Function will be used to process balance forward transactions.


Using receipt information as input parameters, select invoices for the requested customer.


Check if each invoice should be paid, call Calculate Receipt Amount to Apply function (B03B0028) to 

return amount to pay and discount to be taken.

 

Call the invoice match function (ARApplyReceipttoInvoice - B03B0012) to create payment records   

(including write-off amounts and currency gains/losses) and update the receipt and invoice records for 

amounts applied.



Setup Notes and Prerequisites

None.

Special Logic

None.


Technical Specification


Parameters

Item  DescriptionI/OReq?Notes

AN8  mnAddressnumberIYesCustomer address number to process
PYID  mnPaymentIDIYesReceipt PYID

CO  szCompanyIYesReceipt company used to filter invoices

ICUT  szBatchtypeIYesBatch type

ICU  mnBatchnumberIYesBatch Number

DICJ  jdDatebatchjulianIYesBatch Date

AAP  mnAmountopenIYesReceipt open amount domestic

FAP  mnAmountforeignopenIYesReceipt open amount foreign

CRR  mnCurrencyconverrateovIYesReceipt exchange rate

CRRM  cCurrencymodeIYesReceipt currency mode

CRCD  szCurrencycodefromIYesReceipt currency

RMKS  zNameremarkIYesReceipt remark

MATH01  mnMaxAutoDebitWrOffIYesMax amount for auto writeoffs debit

AR  szDbWrOffReasonCdIYesDefault reason code to use for debit writeoff

DGJ  jdDateforglandvoucherjuliaIYesReceipt G/l date

MATH02  mnMaxAutoCreditWrOffIYesMax amount for auto writeoffs credit 

VC02A  szCrWrOffReasonCdIYesDefault reason code to use for credit writeoff

EV01  cAllowPaymentHeldInvIYesoption to allow payment of only active invoices or 

held invoice

EV02  cAllowDiscTakenIYesAllow discounts 1- Y0es else- No

EV04  cApplyDueDateIYes1- Take all discounts, Else- Only earned discounts

EV03  cSpreadMethodNNAParm Not Used

DIVJ  jdStartInvoiceDateIYesSelect invoice with invoice date GE this date

INT01  nErrorFlagNNAParm Not Used

EV05  cSkipAutoWriteOffIYes1- Skip auto writeoff process in B03B0012 Else- Check 

for Auto Writeoffs

DOC  mnDocvoucherinvoiceeIOptInvoice number to process only this invoice

EV10  cCreatRUDetailIYesPass 'N' if do not want Unapplied Cash records to be 

created in F03B11 and F03B14 tables; pass 'Y' or blank if want this BF to be called.

CRR  mnRectTriangulationRate1IYesReceipt triangulation leg 1 Euro

CRR  mnRectTriangulationRate2IYesReceipt triangulation leg 2 Euro

CRCM  cRectCurrencyConversionMeIYesReceipt conversion method Euro

EFTDT  jdRectTransactionDateIYesReceipt exchange rate effective date




Related Tables

F03B11Customer LedgerInput



Related Functions

B0000027 CurrencyConvForAndDom
B0000055ValidateAAICompletely

B0000128GetCoCurrency

B0000173Determine Date, Conversion Method and Rates

B03B0012 ARApplyReceipttoInvoice

B03B0028CalculateAmountTotPay

B03B0069Create Maintain RU Detail

B03B0174Get Invoice Exchange Rate For Euro




Processing


if receipt open amount less than or equal to zero - set on error.

if maximum write-off amount (processing options) not zero but write-off reason code is blank - set on 

error.


Open table F03B11 (using index as defined above) and using a select structure, select invoices where:


invoice customer number equal to receipt customer.
pay status not 'S' or 'P'.

invoice company equal to receipt company.

not a draft (document type 'R1').

open invoice amount greater than zero.

due date greater than start date (processing options). 


Retrieve receipt base currency (use function COCURR).


Read selected F03B11 records in a loop until all records read or remaining receipt open amount is 

zero. For each invoice read:


call internal function to validate invoice.
if valid invoice, call B03B0028 to calculate amount to apply and discount to apply.

if valid invoice, call internal function to set parameters and call external function (B03B0012) 

to apply payment to invoice.


Validate Invoice internal function:


if not allowing payment of non-approved invoices (processing option) and invoice pay status is not 
equal to 'A' - reject.


if a foreign receipt and invoice and receipt currency codes are different - reject.



Call Invoice Match internal function:


load function B03B0012 parameters.
call external function to apply receipt (B03B0012).

if B03B0012 returns a successfully completed code, subtract amount applied from receipt open 

amount remaining. 



Data Structure

D03B0030 - Balance Forward Receipts

Item  DescriptionI/OReq?Notes
AN8  mnAddressnumberIYesCustomer address number to process
PYID  mnPaymentIDIYesReceipt PYID

CO  szCompanyIYesReceipt company used to filter invoices

ICUT  szBatchtypeIYesBatch type

ICU  mnBatchnumberIYesBatch Number

DICJ  jdDatebatchjulianIYesBatch Date

AAP  mnAmountopenIYesReceipt open amount domestic

FAP  mnAmountforeignopenIYesReceipt open amount foreign

CRR  mnCurrencyconverrateovIYesReceipt exchange rate

CRRM  cCurrencymodeIYesReceipt currency mode

CRCD  szCurrencycodefromIYesReceipt currency

RMKS  zNameremarkIYesReceipt remark

MATH01  mnMaxAutoDebitWrOffIYesMax amount for auto writeoffs debit

AR  szDbWrOffReasonCdIYesDefault reason code to use for debit writeoff

DGJ  jdDateforglandvoucherjuliaIYesReceipt G/l date

MATH02  mnMaxAutoCreditWrOffIYesMax amount for auto writeoffs credit 

VC02A  szCrWrOffReasonCdIYesDefault reason code to use for credit writeoff

EV01  cAllowPaymentHeldInvIYesoption to allow payment of only active invoices or 

held invoice

EV02  cAllowDiscTakenIYesAllow discounts 1- Y0es else- No

EV04  cApplyDueDateIYes1- Take all discounts, Else- Only earned discounts

EV03  cSpreadMethodNNAParm Not Used

DIVJ  jdStartInvoiceDateIYesSelect invoice with invoice date GE this date

INT01  nErrorFlagNNAParm Not Used

EV05  cSkipAutoWriteOffIYes1- Skip auto writeoff process in B03B0012 Else- Check 

for Auto Writeoffs

DOC  mnDocvoucherinvoiceeIOptInvoice number to process only this invoice

EV10  cCreatRUDetailIYesPass 'N' if do not want Unapplied Cash records to be 

created in F03B11 and F03B14 tables; pass 'Y' or blank if want this BF to be called.

CRR  mnRectTriangulationRate1IYesReceipt triangulation leg 1 Euro

CRR  mnRectTriangulationRate2IYesReceipt triangulation leg 2 Euro

CRCM  cRectCurrencyConversionMeIYesReceipt conversion method Euro

EFTDT  jdRectTransactionDateIYesReceipt exchange rate effective date


^

Parameter NameData ItemData TypeReq/OptI/O/Both
mnAddressnumberAN8MATH_NUMERICNONENONE

A number that identifies an entry in the Address Book system, such as employee, applicant, participant, customer, supplier, tenant, or 
location.

mnPaymentidPYIDMATH_NUMERICNONENONE

A number that the system assigns from Next Numbers to identify and track payment records.

szCompanyCOcharNONENONE

A code that identifies a specific organization, fund, or other reporting entity. The company code must already exist in the Company 
Constants table (F0010) and must identify a reporting entity that has a complete balance sheet. At this level, you can have intercompany 
transactions. Note: You can use company 00000 for default values such as dates and automatic accounting instructions. You cannot use company 00000 
for transaction entries.

szBatchtypeICUTcharNONENONE

A code that specifies the system and type of transactions entered in a batch. The system assigns the value when you enter a transaction. 
Valid values are set up in user defined code table 98/IT. You cannot assign new values. All batch types are hard coded.

mnBatchnumberICUMATH_NUMERICNONENONE

A number that identifies a group of transactions that the system processes and balances as a unit. When you enter a batch, you can either 
assign a batch number or let the system assign it using the Next Numbers program.

jdDatebatchjulianDICJJDEDATENONENONE

The date of the batch. If you leave this field blank, the system date is used.

jdDateforglandvoucherjuliaDGJJDEDATENONENONE

A date that identifies the financial period to which the transaction will be posted. You define financial periods for a date pattern code that you 
assign to the company record. The system compares the date that you enter on the transaction to the fiscal date pattern assigned to the 
company to retrieve the appropriate fiscal period number, as well as to perform date validations.

mnAmountopenAAPMATH_NUMERICNONENONE

The amount of an invoice or voucher pay item that is unpaid.

mnAmountforeignopenFAPMATH_NUMERICNONENONE

The unpaid foreign amount of a transaction.

mnCurrencyconverrateovCRRMATH_NUMERICNONENONE

A number (exchange rate) that a foreign currency amount is multiplied by to calculate a domestic currency amount.  The number in this field 
can have a maximum of seven decimal positions. If more are entered, the system adjusts to the nearest seven decimal positions. 

cCurrencymodeCRRMcharNONENONE

An option that specifies whether the system displays amounts in the domestic or foreign currency. On  The system displays amounts in the 
foreign currency of the transaction. Off  The system displays amounts in the domestic currency of the transaction.

szCurrencycodefromCRCDcharNONENONE

A code that identifies the currency of a transaction. 

szNameremarkRMKcharNONENONE

A generic field that you use for a remark, description, name, or address.

mnDocvoucherinvoiceeDOCMATH_NUMERICNONENONE

A number that identifies the original document, such as a voucher, invoice, or journal entry. On entry forms, you can assign the document 
number or let the system assign it using the Next Numbers program (P0002). Matching document numbers (DOCM) identify related documents 
in the Accounts Receivable and Accounts Payable systems. Examples of original and matching documents are: Accounts Payable     o 
Original document - voucher     o Matching document - payment  Accounts Receivable     o Original document - invoice     o Matching document - 
receipt  Note: In the Accounts Receivable system, the following transactions simultaneously generate original and matching documents: 
deductions, unapplied receipts, chargebacks, and drafts.

szDocumentpayitemSFXcharNONENONE

A number that identifies the pay item for a voucher or an invoice. The system assigns the pay item number. If the voucher or invoice has 
multiple pay items, the numbers are sequential.

mnMaxAutoDebitWrOffMATH01MATH_NUMERICNONENONE

- - - Good Performance Low Value. 

szDbWrOffReasonCdARcharNONENONE

A code that identifies the reason for an adjustment, or a code that prevents an individual invoice from being included on a payment 
reminder. You define these codes in the AAIs so that the system can make the adjusting entries in the general ledger. Typical reason codes 
are: RABD - Bad Debt Expense (BD is the Adjustment Reason) RADC - Damaged Goods Credit (DC is the Adjustment Reason) RAMW - Minor 
Amount Write Off (MW is the Adjustment Reason) RATF - Tax or Freight Dispute (TF is the Adjustment Reason)

szCrWrOffReasonCdVC02AcharNONENONE

A generic field that is used as a work field.

cAllowPaymentHeldInvEV01charNONENONE

An option that specifies the type of processing for an event.

cAllowDiscTakenEV02charNONENONE

An option that specifies the type of processing for an event.

cApplyDueDateEV03charNONENONE

A radio button that specifies the level at which trace/track result is to be displayed.  Select the Detail to display all transactions except IB, IX, 
and IZ types.  Or, select Derivative Lots Only to display only those transactions that may have created new derivative lot. 

cSpreadMethodEV04charNONENONE

PeopleSoft event point processing flag 04.

jdStartInvDateDATE01JDEDATENONENONE

Event point for JDE Date.

nErrorFlagINT01integerNONENONE

Number of Days in Future to Query for Responses Due. 

cSkipAutoWriteOffEV05charNONENONE

A flag that indicates whether automatic spell check is turned on.

mnMaxAutoCreditWrOffMATH03MATH_NUMERICNONENONE

- - - Bad Performance Low Value. 

szCompanyKeyKCOcharNONENONE

A number that, with the document number, document type and G/L date, uniquely identifies an original document, such as invoice, voucher, 
or journal entry. If you use the Next Numbers by Company/Fiscal Year feature, the Automatic Next Numbers program (X0010) uses the 
document company to retrieve the correct next number for that company. If two or more original documents have the same document number and 
document type, you can use the document company to locate the desired document.

szDocumenttypeDCTcharNONENONE

A user defined code (00/DT) that identifies the origin and purpose of the transaction.  PeopleSoft reserves several prefixes for document 
types, such as, vouchers, invoices, receipts, and timesheets. The reserved document type prefixes for codes are: P Accounts payable 
documents R Accounts receivable documents  T Time and Pay documents I Inventory documents  O Purchase order documents  S Sales order 
documents 

cCallCreateRUDetailEV06charNONENONE

An option that specifies the type of processing for an event.

mnRectTriangulationRate1CRRMATH_NUMERICOPTNONE

A number (exchange rate) that a foreign currency amount is multiplied by to calculate a domestic currency amount.  The number in this field 
can have a maximum of seven decimal positions. If more are entered, the system adjusts to the nearest seven decimal positions. 

mnRectTriangulationRate2CRRMATH_NUMERICOPTNONE

A number (exchange rate) that a foreign currency amount is multiplied by to calculate a domestic currency amount.  The number in this field 
can have a maximum of seven decimal positions. If more are entered, the system adjusts to the nearest seven decimal positions. 

cRectCurrencyConversionMethodCRCMcharOPTNONE

A value that specifies which method to use when converting from one currency to another. Valid values are:  Y  Multiplier method. The 
system multiplies the foreign amount by the multiplier exchange rate to calculate the domestic amount. Z Divisor method. The system divides the 
foreign amount by the divisor exchange rate to calculate the domestic amount.

jdRectTransactionDateEFTJDEDATEOPTNONE

The date that identifies when a date is first valid. The effective date is used generically. It can be a lease effective date, a price or cost 
effective date, a currency effective date, a tax rate effective date, or whatever is appropriate.

szDiscountReasonCodeDRCOcharOPTNONE

A code that specifies the reason that a discount is given.

szCurrencyCodeBaseBCRCcharOPTNONE

A code that represents the currency of the company for a transaction. For a foreign currency transaction, this is the currency code of the 
domestic side of the transaction.

Related Functions

B0000027 CurrencyConvForAndDom
B0000055 ValidateAAICompletely
B0000128 Retrieve Company Currency Code
B03B0012 F03B14 Apply Receipt to Invoice
B03B0028 Calculate Amount to Pay
B03B0069 F03B14 Maintain Unapplied Cash
B03B0174 Get Invoice Exchange Rate For Euro

Related Tables

F03B11 Customer Ledger