UpdateF4111ForSalesUpdate

UpdateF4111ForSalesUpdate

Major Business Rule

Object Name: B4200670

Parent DLL: CDIST

Location: Client/Server

Language: C





Functional Description


Purpose


This function will only be called if inventory was updated in Shipment Confirmation(P4205). The F4111 

record will be fetched with sales order number,sales order type,and sales order key company in the 

doc,dct,and kco fields and sales order line number to LNID.. If no record exists in the file bypass 

processing. If there is a record and the As Of Posted is either Y or S then the GL Date, Batch Number, and 

As Of Posted Code will be updated. NOTE: In addition to the update of ICU,DG and IPCD this record 

will have the key fields changed from sales order number,type,co to invoice number,type ,co. The sales 

order line number will remain the same.


Setup Notes and Prerequisites

None.


Special Logic


At this time Transfer Orders and Summarization are not being done. When they are the calling  app 

will determine which Document Number,Type,Key Company, and Batch Number to pass. In the future there can 

be a batch for transfers, a batch for inventory and cost of goods summarized to a separate batch, and 

the batch of sales and AR entries.At this time there is only one batch.

P.S. Transfer Orders and Summarization are now being handled correctly from the calling program 

(Sales Update).



Technical Specification



Related Tables 


Table Table Description


F4111      Item Ledger





Related Business Functions


None.




Processing 


1.Retrieve the F4111 record by DOCO,DCTO,KCOO,LNID (partial keyed fetch)

2.If there isn't a record in F4111 bypass processing

else

  If ILIPCD is equal S or Y

copy blanks toILIPCD

copy DGL to ILDGL

copy ICU to ILICU

copy DOCO to ILDOC

copy DCTO to ILDCT

copy KCOO to ILKCO


P.S.: For performance improvement, loaded  the full key from the fetch above for the update 

Operation.

update F4111



^

Data Structure

D4200670 - UpdateF4111ForSalesUpdate





Special Input Expected


Parameters:


Data Item Data Structure DescriptionI/ORequiredNotes

DOCO      Sales Order Number       I   Y      Load to DOC for the

                                                            fetch

DCTO      Sales Order Doc Type       I   Y      Load to DCT for the

                                                            fetch

KCOO      Sales Order Doc Company       I   Y      Load to KCO for the

                                                            fetch

LNID      Sales Order Line Number       I   Y      Load to LNID for the

                                                            fetch

DGL      General Ledger Date       I   Y


ICU      Batch Number             I   Y


DOC      Document No.(invoice)       I   Y      Load to DOC if fetch

                                                            succeeded

DCT      Document Type(invoice)       I   Y      Load to DCT if fetch

                                                            succeeded

KCO      Doc Key Co.(invoice)       I   Y      Load to KCO if fetch

                                                            succeeded



Special Output Returned


None.



^

Parameter NameData ItemData TypeReq/OptI/O/Both
mnSalesOrderNumberDOCOMATH_NUMERICNONENONE

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.

szOrderTypeDCTOcharNONENONE

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

szSalesOrderDocCompanyKCOOcharNONENONE

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.

mnLineNumberLNIDMATH_NUMERICNONENONE

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.

jdGeneralLedgerDateDGLJDEDATENONENONE

A date that identifies the financial period to which the transaction is to be posted.  The company constants specify the date range for each 
financial period. You can have as many as 14 periods. Generally, period 14 is used for audit adjustments. The system validates this field for 
PBCO (posted before cutoff), PYEB (prior year ending balance), PACO (post after cutoff), and WACO (post way after cutoff) messages.

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.

mnDocumentNumberDOCMATH_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.

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 

szDocKeyCoKCOcharNONENONE

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.

szErrorMessageDTAIcharNONENONE

A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or 
special characters such as %, &, or +. You create new data items using system codes 55-59. You cannot change the alias.

cSuppressErrorMessageEV01charNONENONE

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

cErrorCodeERRCcharNONENONE

This error code indicates if any errors occurred during the creation of the Trip Document Detail (F4914) records by the Delivery Document 
Set Server program (XT4914).

Related Functions

None

Related Tables

F4111 Item Ledger File