1.Functional Description
1.1Purpose
This function reads Routing information to create Resource Profile records (F3303) for the input Item
and Branch.
1.2Setup Notes and Prerequisites
1.3Special Logic
2.Technical Specifications
// Initialize variables
LastLineType = ' '
LastWorkCenter = ' '
InventoryInterfaceFlag = ' '
// If originating from component, calculate quantity per
If ParentItemFlag = ' '
WkQuantity = 1
Fetch the F4101 record for the input BOMComponentItem
If fetch successful
If IMLNTY <> LastLineType
Interface value (IVI)
InventoryInterfaceFlag = InventoryInterfaceFlag from B4000260
LastLineType = IMLNTY
End
// Convert quantity to Primary UOM
If InventoryInterfaceFlag = 'Y' or 'D'
PrimaryUOM = F4101 IMUOM1
Else
PrimaryUOM = UnitOfMeasure
End
TempQty = BOMQuantity
Call B4000520, Get Item UOM Conversion Factor, to convert TempQty from UnitOfMeasure to
PrimaryUOM for BOMComponentItem and ComponentBranch. Pass InventoryInterfaceFlag and Standard UOM
Conversion (IMTFLA)
If not successful
WkQuantity = 1
Else
WkQuantity = TempQty
End
SaveParentItem = BOMComponentItem
// If Master Routing, use Cross Reference Item Number
If MasterRoutingFlag = 'Y'
'MR', and Address Number (AN8) = 0.
If the fetch is successful
Fetch the F4101 record for the cross reference item (IVCITM) from F4104
If fetch successful
Fetch a record from F3003 for F4101 IMITM and Branch
If fetch successful
SaveParentItem = IMCITM
End
End
End
// Assign F3303 field values
F3303 CTITM = ShortItemNumber
F3303 CTLITM = SecondItemNumber
F3303 CTAITM = ThirdItemNumber
F3303 CTMMCU = Branch
F3303 CTUM = 'HR'
// Retrieve Routing Information
Set a selection over F3003 using key values SaveParentItem, Branch, TRT = 'M ', BQTY = Accounting
Cost Quantity.
Fetch the first selected record from F3003
If the fetch fails
Fetch the first selected record from F3003
FirstPass = TRUE
While F3003 fetch successful
If(IXEFFF >= EffectiveFromDate and IXEFFF <= EffectiveThruDate) or
// Check for an Intermediate Item
IntermediateFlag = FALSE
IRBQTY, And IROPSQ.
If fetch successful
IntermediteFlag = TRUE
Fetch the F4101 record for IXITM
If fetch successful
If IMLNTY <> LastLineType
Inventory Interface value (IVI)
B4000260
LastLineType = IMLNTY
If InventoryInterfaceFlag = 'Y' or 'D'
PrimaryUOM = F4101 IMUOM1
Else
PrimaryUOM = F3002 IXUM
End
TempQty = F3002 IXQNTY
If IXFORQ = '%'
Divide TempQty by 100
End
to PrimaryUOM for IXITM, IXCMCU. Pass
InventoryInterfaceFlag and Standard UOM Conversion (IMTFLA)
If not successful
// Calculate Operation Yield Percentage
If IRCPYP <> 0
Divide IRCPYP by 100
Divide WkQuantity2 by IRCPYP
End
// Convert quantity per into BOM UOM
FromUOM = F4101 IMUOM1
Else
FromUOM = F3002 IXUM
End
PrimaryUOM = F3002 IXUM
TempQty = WkQuantity2
FromUOM to PrimaryUOM for IXITM, IXCMCU. Pass
InventoryInterfaceFlag and Standard UOM Conversion (IMTFLA)
If not successful
WkQuantity2 = 0
Else
End
// Get conversion factor for parent item into primary UOM
If FirstPass = TRUE
ConvFactor = 1
Fetch the F4101 record for F3003 IRKIT
to IMUOM for IRKIT, IRMMCU. Pass InventoryInterfaceFlag = 'Y' and Standard UOM Conversion
(IMTFLA).
If not successful
End
FirstPass = FALSE
// Retrieve Work Center Information
If IRMCU <> LastWorkCenter
LastWorkCenter = IRMCU
If fetch successful
Else
ResourceOffset = 0
// Assign F3303 field values
F3303 CTEFFF = EffectiveFromDate
F3303 CTEFFT = EffectiveThruDate
F3303 CTTRKS = ResourceOffset
F3303 CTTIMB = IRTIMB
F3303 CTMCU = IRMCU
// Revise Effectivity for Routing
If IREFFF > EffectiveFromDate
CTEFFF = IREFFF
End
If IREFFT < EffectiveThruDate
CTEFFT = IREFFT
End
// Write Resource Profile for Labor
If IRRUNL <> 0
CTUORG = IRRUNL * WkQuantity * ConvFactor
If IntermediateFlag = TRUE
CTUORG = CTUORG * WkQuantity2
Else
If IRCPYP <> 0
CTUORG = CTUORG / (IRCPYP / 100)
End
End
CTUNTY = '1'
TempQty = CTUORG
CTEFFT, And CTTIMB.
If fetch successful
Add TempQty to the fetched CTUORG and update the F3303 record
Else
Find the greatest Unique Key ID (CTUKID) value in the F3303
table
Add 1 to CTUKID
Add a new record to F3303 using the field values assigned
above.
End
// Write Resource Profile for Setup
If IRSETL <> 0
CTUORG = IRSETL
CTUNTY = '2'
TempQty = CTUORG
CTEFFT, And CTTIMB.
If fetch successful
Add TempQty to the fetched CTUORG and update the F3303 record
Else
Find the greatest Unique Key ID (CTUKID) value in the F3303
table
Add 1 to CTUKID
Add a new record to F3303 using the field values assigned
above.
End
// Write Resource Profile for Machine
If IRRUNM <> 0
CTUORG = IRRUNM * WkQuantity * ConvFactor
If IntermediateFlag = TRUE
CTUORG = CTUORG * WkQuantity2
Else
If IRCPYP <> 0
CTUORG = CTUORG / (IRCPYP / 100)
End
End
CTUNTY = '3'
TempQty = CTUORG
CTEFFT, And CTTIMB.
If fetch successful
Add TempQty to the fetched CTUORG and update the F3303 record
Else
Find the greatest Unique Key ID (CTUKID) value in the F3303
table
Add 1 to CTUKID
Add a new record to F3303 using the field values assigned
above.
End
End
^
D3300110 - F3303, Create Resource Profile From Routing
Data Item Data Structure DescriptionI/ORequiredNotes
EV01 Parent Item Flag IY '1' = Parent Item
' ' = Component Item
MMCU Branch IY IBMCU
ITM Short Item Number IY IBITM
LITM Second Item Number IY
AITM Third Item Number IY
ITM BOM Component Item IY IXITM from F3002
CMCU Component Branch IY IXCMCU from F3002
UM Unit Of Measure IY IXUM from F3002
QNTY BOM Quantity IY IXQNTY from F3002
EFFF Effective From Date IY
EFFT Effective Thru Date IY
MRYN Master Routing Flag IY
ACQ Acounting Cost Quantity IY
SUPPS Suppress Error Message IY '1' = Suppress error messages
' ' = Allow error messages
DTAI Error Message ID OY ' ' = success
'3143' = file cannot be
accessed
^
Parameter Name | Data Item | Data Type | Req/Opt | I/O/Both |
---|---|---|---|---|
cParentItemFlag | EV01 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
szBranch | MMCU | char | NONE | NONE |
A code that represents a high-level business unit. Use this code to refer to a branch or plant that might have departments or jobs, which
| ||||
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
| ||||
szSecondItemNumber | LITM | char | NONE | NONE |
A number that identifies the item. The system provides three separate item numbers plus an extensive cross-reference capability to
| ||||
szThirdItemNumber | AITM | char | NONE | NONE |
The system provides three separate item numbers plus an extensive cross-reference capability to alternate item numbers. These item
| ||||
mnBOMComponentItem | 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
| ||||
szComponentBranch | CMCU | char | NONE | NONE |
A secondary or lower-level business unit. The system uses the value that you enter to indicate that a branch or plant contains several
| ||||
szUnitOfMeasure | UM | char | NONE | NONE |
A user defined code (00/UM) that identifies the unit of measurement for an amount or quantity. For example, it can represent a barrel, box,
| ||||
mnBOMQuantity | QNTY | MATH_NUMERIC | NONE | NONE |
The number of units that the system applies to the transaction. | ||||
jdEffectiveFromDate | 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
| ||||
jdEffectiveThruDate | 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
| ||||
cMasterRoutingYN | MRYN | char | NONE | NONE |
An option that determines whether the system uses the master routing for an item or a routing defined for the parent item. Both routings are
| ||||
cSuppressErrorMessage | SUPPS | char | NONE | NONE |
A flag indicating whether or not runtime error messaging will occur when an error message is issued from a business function.
0 = allow
| ||||
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
| ||||
mnAccountingCostQty | ACQ | MATH_NUMERIC | NONE | NONE |
An amount that the system uses in the Cost Rollup program to determine the allocation of setup costs. The system totals the setup costs
|
B3100490 Get Next Unique ID For Mfg. | ||||
B4000260 Line Type - Activity Rules | ||||
B4000520 Get Item UoM Conversion Factor | ||||
B9800420 Get Data Dictionary Definition | ||||
X4101 Validate and Retrieve Item Master |
F30006 Work Center Master File | ||||
F3002 Bill of Material Master File | ||||
F3003 Routing Master File | ||||
F3303 Capacity Resource Profile | ||||
F4101 Item Master | ||||
F4104 Item Cross Reference File |