UPdatePODetailFromHeader

Update PO Detail From Header

Major Business Rule

Object Name: B4300090

Parent DLL: CDIST

Location: Client/Server

Language: C

Functional Description

Purpose

Update all the detail records related to this order with the Supplier number and Ship-to address from 

the header file.  This is in the event that the header file has been changed.


Technical Specification

Edits:

None


Retrievals:

Retrieve all the records from the F4311 table (Purchase Order Detail) using the DOCO, DCTO and KCOO 

as key.  THERE WILL PROBABLY BE MULTIPLE OCCURANCES.  


For each record fetched, update the field AN8 from F4311 with the AN8 from the Data Structure and 

SHAN from F4311 with SHAN from the Data Structure.


Update the following fields before update of fetched record :

PDUSER

PDPID

PDJOBN

PDUPMJ

PDTDAY


PID is taken from the GBR Data Structure.


The Other fields are retrieved from the Business Function called GetAuditInfo.

These are :

  char             szUserName[11];               -> PDUSER

  JDEDATE          jdDate;                       -> PDTDAY

  MATH_NUMERIC     mnTime;                       -> PDUPMJ

  char             szWorkstation_UserId[11];     -> PDJOBN



Update the F4311 record fetched.


Data Structure

D4300090 - UPdatePODetailFromHeader

Parameter NameData ItemData TypeReq/OptI/O/Both
mnShipToAddressSHANMATH_NUMERICNONENONE

The address number of the location to which you want to ship this order. The address book provides default values for customer address, 
including street, city, state, zip code, and country.

mnSupplierNumberAN8MATH_NUMERICNONENONE

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

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

szProgramIDPIDcharNONENONE

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.

szDocumentTypeDCTOcharNONENONE

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

szKeyCompanyKCOOcharNONENONE

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.

Related Functions

B9800100 Get Audit Information

Related Tables

F4311 Purchase Order Detail File