AdjustF4822SubsequentInvoices

Adjust F4822 Subsequent Invoices

Minor Business Rule

Object Name: N5200202

Parent DLL: CCRIN

Location: Client/Server

Language: NER

Adjust F4822 Subsequent Invoices
Source Name:N5200202
Data Structure: D5200202

Function Name:AdjustF4822SubsequentInvoices

System Code:52  Contract Billing
Function Category:
BAT
Function Use:
UPD
Designer:
Ira Frosch
Programmer:Ira Frosch



Revisions Log 
  Date  Modified bySAR NumberDescription
4 Aug 99Ira Frosch3231605Creation



1.Functional Description

1.1Purpose
This business function adjusts all F4822 records after the specified application and adjustment 
number with an updated amount.


1.2Setup Notes and Prerequisites

The application number and adjustment number must be inputted.

1.3Special Logic

This routine needs to do the following steps in order:

1.Select all F4822 for this billing line where the application number is equal to or greater than 
the parameter

2.Fetch Next F4822

3.If the application number is equal to the parameter and the adjustment number is less than or 

equal to the adjustment number parameter, skip updating (as it will have no effect).

4.Update the Prior Units and all prior amounts fields (Foreign and Domestic) with the input 

parameters

5.Update the F4822 record

6.Repeat steps 2-5 until End of Table



2.Technical Specifications


2.1Parameters:

See attachment of D5200202.

2.2Related Tables

Table Table Description
F4822Invoice Summary Work File

2.3Related Business Functions

Source NameFunction Name
GetAuditInformation


2.4Processing 

//
F4822.Open

//

// Select all valid records for update

//

F4822.Select (DOCO,DCTO,KCOO,COCH,LNID, APPL >= BF mnApplicationNo)

//

// Loop over records until found

//

Do while evt_cF4822Status = evt_cOK

F4822.FetchNext
If evt_cF4822Status = evt_cOK

//

// Insure that application number is greater than input, or if the same, the adjustment no is greater

//

If evt_mnApplicationNo > BF mnApplicationNo

Or evt_mnApplicationNo = BF mnApplicationNo
And evt_mnAdjustmentNo > BF mnAdjustmentNo
evt_F4822PriorUnits = evt_F4822PriorUnits + BF mnPriorUnits

// Complete rest of Fields

F4822.Update
Endif

Endif
End While

F4822.Close


Data Structure

D5200202 - Adjust F4822 Subsequent Invoices

D5200202
Adjust F4822 Subsequent Invoices


Parameters:


Data
Item Data Structure DescriptionI/ORequiredNotes
PIDszCallingProgramIDIY
DOCOmnContractNoIY

DCTOszContractDocumentTypeIY

KCOOszContractKeyCoIY

COCHszContractChangeOrderIY

LNIDmnContractLineNoIY

APPLmnApplicationNoIY

ADJNmnAdjustmentNoIY

PUHPmnPriorUnitsIY

PTHPmnPriorThisPeriodIY

PATXmnPriorInvoiceTaxableIY

PTAMmnPriorInvTaxAmtIY

PSMAmnPriorMiscInvIY

RTNPmnPriorRetainageIY

SMRPmnPriorMiscRetAmtIY

FTHPmnForPriorThisPeriodIY

FATXmnForPriorInvTaxableIY

FPTAmnForPriorInvTaxAmtIY

FSMAmnForPriorMiscInvIY

FTNGmnForPriorRetainageIY

SMRFmnForPriorMiscRetAmtIY



Parameter NameData ItemData TypeReq/OptI/O/Both
szCallingProgramIdPIDcharOPTNONE

The number that identifies the batch or interactive program (batch or interactive object). For example, the number of the Sales Order Entry 
interactive program is P4210, and the number of the Print Invoices batch process report is R42565. The program ID is a variable length value. 
It is assigned according to a structured syntax in the form TSSXXX, where: T The first character of the number is alphabetic and identifies the 
type, such as P for Program, R for Report, and so on. For example, the value P in the number P4210 indicates that the object is a 
program. SS The second and third characters of the number are numeric and identify the system code. For example, the value 42 in the number P4210 
indicates that this program belongs to system 42, which is the Sales Order Processing system. XXX The remaining characters of the numer are 
numeric and identify a unique program or report. For example, the value 10 in the number P4210 indicates that this is the Sales Order Entry 
program.

mnContractNoDOCOMATH_NUMERICOPTNONE

A number that identifies an original document. This document can be a voucher, a sales order, an invoice, unapplied cash, a journal entry, 
and so on.

szContractDocumentTypeDCTOcharOPTNONE

A user defined code (00/DT) that identifies the type of document. This code also indicates the origin of the transaction. J.D. Edwards has 
reserved document type codes for vouchers, invoices, receipts, and time sheets, which create automatic offset entries during the post 
program. (These entries are not self-balancing when you originally enter them.) The following document types are defined by J.D. Edwards and 
should not be changed: P Accounts Payable documents   R Accounts Receivable documents   T Payroll documents   I Inventory documents  
O Purchase Order Processing documents   J General Accounting/Joint Interest Billing documents   S Sales Order Processing documents

szContractKeyCoKCOOcharOPTNONE

A number that, along with order number and order type, uniquely identifies an order document (such as a purchase order, a contract, a 
sales order, and so on). If you use the Next Numbers by Company/Fiscal Year facility, the Automatic Next Numbers program (X0010) uses the 
order company to retrieve the correct next number for that company. If two or more order documents have the same order number and order 
type, the order company lets you locate the desired document. If you use the regular Next Numbers facility, the order company is not used to 
assign a next number. In this case, you probably would not use the order company to locate the document.

szContractChgOrderCOCHcharOPTNONE

The change number of the contract. The change order number of the base contract is always initialized to 000. Each time you enter a 
change order for a contract, the system automatically increases the change order number by one. For example, the base contract is the change 
order number 000, the first change order is 001, the second is 002, and so on.

mnContractLineNoLNIDMATH_NUMERICOPTNONE

A number that identifies multiple occurrences, such as line numbers on a purchase order or other document. Generally, the system assigns 
this number,but in some cases you can override it.

mnApplicationNoAPPLMATH_NUMERICOPTNONE

The last or current application number for the specified contract. (The system assigns a new application number each time an invoice is 
issued for the contract.)

mnAdjustmentNoADJNMATH_NUMERICOPTNONE

A number used to control changes to closed applications. Closed applications represent invoices that have been sent. This number is 
always zero unless you reopen a previous application.

mnPriorUnitsPUHPMATH_NUMERICOPTNONE

The units previously billed this period for the line item on the contract.

mnPriorInvTotalAmtPTHPMATH_NUMERICOPTNONE


mnPriorInvTaxableAmtPATXMATH_NUMERICOPTNONE


mnPriorStoredMatInvAmtPSMAMATH_NUMERICOPTNONE

The amount previously billed for Stored Material for the line item on the contract.

mnPriorRetAmtRTNPMATH_NUMERICOPTNONE

Retainage Amount through the last application or adjustment for a specific contract.

mnForPriorInvTotalAmtFTHPMATH_NUMERICOPTNONE


mnForPriorInvTaxableAmtFATXMATH_NUMERICOPTNONE


mnForPriorStoredMatInvAmtFSMAMATH_NUMERICOPTNONE

The amount previously billed for Stored Material for the line item on the contract.

mnForPriorRetAmtFTNGMATH_NUMERICOPTNONE

xThis field is the retained dollars for a contract line.

mnPriorInvTaxAmtPTAMMATH_NUMERICOPTNONE

The tax amount previously billed for the billing line on the contract.

mnPriorStoredMatRetAmtSMRPMATH_NUMERICOPTNONE

The prior retained amount for the stored materials.

mnForPriorInvTaxAmtFPTAMATH_NUMERICOPTNONE

The foreign tax amount previously billed for the billing line on the contract.

mnForPriorStoredMatRetAmtSMPFMATH_NUMERICOPTNONE

Related Functions

None

Related Tables

None