1.Functional Description
This business function will get read the Purchase Order table (F4311) and Load the Open Quantity
Calculated in the Item Qty Cache in the Primary Unit of Measure. It will also cache the Purchase Order
records that were selected for use and store the PO quantities in the Primary UOM.
1.1Purpose
This function is used to obtain data from the F4311 table for the MRP Planning Program P3482. The
function will return error codes necessary.
1.2Setup Notes and Prerequisites
It is assumed at the time this function is called, the PO Cache has no residual data on the same Item
and Branch. Otherwise duplicate POs will be in the cache.
1.3Special Logic
None
2.Technical Specifications
The following actions have to be performed by the Business Function.
1.Open Tables and Initialize Data
Open F4311, F34004 and F3411 tables
If Error in Opening the Tables, Exit the function with an Error code = '1'
If Input Receipt Routing flag = '1'
Open F43092
If Error in Opening F43092
Input Rec Rtg Flag = ' '.
Endif
Endif
Output PO flag = '0'.
2. Load the Purchase Order Data in the Cache and cache the PO record if not already cached.
If Input Consolidation Method = '1' then
Wk PO Branch = Input Date Branch
Wk Cache Branch = Input Date Branch
Else
Wk PO Branch = Input Branch
Wk Cache Branch = Input Branch
End IF
Switch (Input Number of Past Due Periods $PDUE)
Case 0
If Forecast Consumption Flag($$FCP) = '1'
Wk From Date = Input Forecast Beginning Date($$FBDT)
Else
Wk From Date = Input Begin Date ($$BEG)
End If
Wk From Date <= PDPDDJ <= Input Last Date
If Forecast Consumption Flag($$FCP) = '1'
Branch and Input Forecast Beginning Date($$FBDT) <= PDPDDJ <= Input Last Date
Branch and PDPDDJ <= Input Last Date
Case 2
Branch and PDPDDJ <= Input Last Date
Wk Exit Flag = '0'
If Fetch Failed
Break
Endif
If PDPDDJ = 0
Continue
Endif
PDNXTR.
Continue
Endif
Wk Quantity = PDUOPN
If Wk Quantity > 0 and PDUOM <> Input UOM1 Or PDUOM <> PDUOM3 Or Input
SVOT1Y = 'Y'
Convert Wk Quantity from PDUOM to Input UOM1 using B4000520
Endif
Wk Rec Rtg Qty = 0
If Rec Rout Code PDRTGC = 'Y' and Input Rec Rtg flag = '1'
Wk Index = 1
While Wk Index <= 5
Wk UPIB = Blanks
Case Wk Index = 1
Wk UPIB = 'PREQ'
Case Wk Index = 2 and Input Trans flag <> '1'
Wk UPIB = 'QTTR'
Case Wk Index = 3 and Input Inspect flag <> '1'
Wk UPIB = 'QTIN'
Case Wk Index = 4 and Input Other1 flag <> '1'
Wk UPIB = 'QTO1'
Case Wk Index = 5 and Input Other2 flag <> '1'
Wk UPIB = 'QTO2'
End Case
If Wk UPIB <> Blanks
While Wk Exit flag 1 <> '1'
Read the F43092 rows using PDRTGC, Wk UPIB, PDDOCO,
PDDCTO, PDKCOO,PDSFXO, PDLNID as keys
If not found
Break
Endif
Wk Quantity 1 = PXQTYO
If PXUOM <> Input UOM1 Or Input Potency Control
Flag(SVOT1Y) ='Y'
Convert Wk Quantity 1 from PXUOM to Input
UOM1 using B4000520
Endif
Wk Rec Rtg Qty = Wk Rec Rtg Qty + Wk Quantity 1
EndWhile
Endif
Add 1 to Wk Index
EndWhile
Endif
If PDUNCD from F4311 <> 'Y' then
Call B3401320 in 'ADD' mode to cache the PO record using PDDOCO, PDDCTO, PDKCOO, PDSFXO,
PDLNID, MCU=Wk PO Branch, PDAN8, PDTRDJ, PDPDDJ, PDITM, PDRORN, PDRCTO, PDRKCO, PDRLLN, EV01 Flag =
' ' and Wk Quantity.
If Wk Quantity > 0 then
Call B3401290 in 'GET' mode to fetch Item Qty cache record using Wk Cache Branch,
PDPDDJ and 'POU'.
Add Wk Quantity to Quantity from Cache record, and
Call B3401290 in 'UPDATE' mode to update the cache record.
Else
Branch,PDPDDJ, 'POU' and with Wk Quantity
End If
If Wk Rec Rtg Quantity > 0 then
PDPDDJ, and 'IR'.
Add Wk Rec Rtg Quantity to Quantity from Cache record, and
Call B3401290 in 'UPDATE' mode to update the cache record.
Else
Branch, PDPDDJ, 'IR' and Wk Rec Rtg Quantity.
End If
PDPDDJ and with Input Date Branch.
Quantity > 0
MMDCTO(PDDCTO), MMLNID(PDLNID), MMKCOO(PDKCOO), MMTRQT(Wk Qty), MMVEND(PDAN8),
MMSTRT(PDTRDJ), MMDSC1(Inp DSC1), MMITM(Inp Item), MMMCU(Wk Cache Branch), MMDRQJ(Wk Bucketless
Date), MMHCLD('A').
Input UKID = Input UKID + 1
Output $$MRPD = '2'
Endif
$@T = '1' and Wk Quantity > 0
MMDCTO(PDDCTO), MMLNID(PDLNID), MMKCOO(PDKCOO), MMTRQT(Wk Qty), MMVEND(PDAN8),
MMSTRT(PDTRDJ), MMDSC1(Inp DSC2), MMITM(Inp Item), MMMCU(Wk Cache Branch), MMDRQJ(Wk Bucketless
Date) MMHCLD('A').
Input UKID = Input UKID + 1
Output $$MRPD = '2'
Endif
Output PO flag = '1'.
EndWhile
3 Close all Tables
Close all Tables
Exit the function with Error Code = 0
D3400420 - MRP, Write Purchase Order Qty To Cache
Parameter Name | Data Item | Data Type | Req/Opt | I/O/Both |
---|---|---|---|---|
mnShortItemNumber | ITM | MATH_NUMERIC | NONE | NONE |
An inventory item number. The system provides three separate item numbers plus an extensive cross-reference capability to other item
| ||||
szBranch | MCU | char | NONE | NONE |
An alphanumeric code that identifies a separate entity within a business for which you want to track costs. For example, a business unit
| ||||
jdBeginDate | EFFF | JDEDATE | NONE | NONE |
A date that indicates one of the following:
o When a component part goes into effect on a bill of material
o When a routing step goes into
| ||||
szDisplayUnitOfMeasure | UOM1 | char | NONE | NONE |
A user defined code (00/UM) that identifies the unit of measure that the system uses to express the quantity of an item, for example, EA
| ||||
cTransitFlag | EV01 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cInspectFlag | EV02 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cOther1Flag | EV03 | char | NONE | NONE |
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,
| ||||
cOther2Flag | EV04 | char | NONE | NONE |
PeopleSoft event point processing flag 04. | ||||
jdMessageDate | DATE01 | JDEDATE | NONE | NONE |
Event point for JDE Date. | ||||
jdRegenerationDate | DATE02 | JDEDATE | NONE | NONE |
Event point for JDE Date. | ||||
cFrozenOrderMsgFlag | EV09 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cPastDueOrderMsgFlag | EV10 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
mnF3411UniqueKeyID | UKID | MATH_NUMERIC | NONE | NONE |
This field is a unique number used to identify a record in a file. | ||||
cSuppressErrorMessages | EV07 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cReceiptRoutingFlag | EV08 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cErrorCode | ERRC | char | NONE | NONE |
This error code indicates if any errors occurred during the creation of the Trip Document Detail (F4914) records by the Delivery Document
| ||||
szErrorMessageID | DTAI | char | NONE | NONE |
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
| ||||
cPurchaseOrderFlag | EV09 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
cMRPMessageFlag | MRPD | char | NONE | NONE |
This code may be used as an additional field to select Item information to print on reports. Once values are loaded into this field, The
| ||||
szFrozenOrderDesc | DSC1 | char | NONE | NONE |
Brief information about an item; a remark or an explanation. | ||||
szPastDueOrderDesc | DSC2 | char | NONE | NONE |
A second, 30-character description, remark, or explanation. | ||||
szProgramid | PID | char | NONE | NONE |
The number that identifies the batch or interactive program (batch or interactive object). For example, the number of the Sales Order Entry
| ||||
szStandardUOMConversion | TFLA | char | NONE | NONE |
Allows you to bypass the item-specific unit of measure and use the standard unit of measure. Valid values are:
blank Use the item-specific
| ||||
mnStandardPotency | STDP | MATH_NUMERIC | NONE | NONE |
The percentage of active ingredients normally found in an item. | ||||
cPotencyControl | OT1Y | char | NONE | NONE |
A code that indicates whether you control the item by potency. | ||||
szJobNumber | JOB | char | NONE | NONE |
Job Number | ||||
jdLastDate | EFFT | JDEDATE | NONE | NONE |
A date that indicates one of the following:
o When a component part is no longer in effect on a bill of material
o When a routing step is no
| ||||
jdForecastBeginningDate | DATE04 | JDEDATE | NONE | NONE |
Event point for JDE Date. | ||||
cForecastConsumptionFlag | EV03 | char | NONE | NONE |
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,
| ||||
nNumberPastDuePeriods | INT01 | integer | NONE | NONE |
Number of Days in Future to Query for Responses Due. | ||||
szDateBranch | MCU | char | NONE | NONE |
An alphanumeric code that identifies a separate entity within a business for which you want to track costs. For example, a business unit
| ||||
cConsolidationMethod | EV01 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
mnUniqueKeyIDOffset | MATH01 | MATH_NUMERIC | OPT | NONE |
- - - Good Performance Low Value. | ||||
cSupplyDemandExists | EV01 | char | OPT | NONE |
An option that specifies the type of processing for an event. | ||||
mnPurchasingEffectiveDays | PEFD | MATH_NUMERIC | OPT | NONE |
The number of days after a purchased item isreceived that a lot becomes available. The system uses this number when calculating and
| ||||
cProjectPlanning | EV01 | char | OPT | NONE |
An option that specifies the type of processing for an event. | ||||
cProjectSpecificItem | EV01 | char | OPT | NONE |
An option that specifies the type of processing for an event. | ||||
mnSequenceNumber | SEQN | MATH_NUMERIC | OPT | NONE |
A number used to organize the table into a logical group for online viewing and reporting. |
B3401270 Cache, Process MRP Bucketless Dates | ||||
B3401290 Cache, Process MRP Item Quantities | ||||
B3401300 Cache, Process MRP Inclusion Rules | ||||
B4000520 Get Item UoM Conversion Factor | ||||
B9800100 Get Audit Information |
F3411 MPS/MRP/DRP Message File | ||||
F43092 Purchase Order Receipt Routing File | ||||
F4311 Purchase Order Detail File |