1.Functional Description
1.1Purpose
The purpose of this function is to trace the multi-level bill of material for the input parent item
and call the function to create Resource Profile records (F3303) based on component item routing
information.
1.2Setup Notes and Prerequisites
The initial call to this function must have the Mode parameter set to '1'. This causes the function
to create the cache used to process each Item/Branch. If the cache creation is successful, the
function automatically switches the Mode to '2' so that the first F4102 record can be processed
immediately.
After all F4102 records have been read, the calling application must call this function with Mode =
'3' so that the cache is destroyed.
1.3Special Logic
2.Technical Specifications
WkQuantity = 1
If Mode = 1
Branch (MCU)
Quantity (QNTY)
Mode = 2
Initialize Cache
End
If Mode = 2
Open F3002
ComponentFound = TRUE
WkLowLevelCode = 1
WkShortItem = ShortItemNumber
WkBranch = Branch
WkUniqueID = 1
Add a record to the cache for the values WkLowLevelCode, WkShortItem, WkUniqueID, WkBranch,
and Quantity =
1.
Call B3300110 passing the following fields:
Parent Item Flag = '1'
Branch = WkBranch
Short Item Number = WkShortItem
Second Item Number = SecondItemNumber
Third Item Number = ThirdItemNumber
BOM Component Item = WkShortItem
Component Branch = ' '
Unit Of Measure = ' '
BOM Quantity = 0
Effective From Date = EffectiveFromDate
Effective Thru Date = EffectiveThruDate
Master Routing Flag = MasterRoutingFlag
Accounting Cost Quantity = AccountingCostQty
Suppress Error Message = ' '
While ComponentFlag = TRUE
ComponentFlag = FALSE
ComponentFound = FALSE
Use CacheFetchPosition to position the cache cursor at the cache recordmatching
WkLowLevelCode
While LowLevelCode from fetched cache record = WkLowLevelCode
ComponentFlag = TRUE
BQTY = AccountingCostQty.
Fetch the first selected record from F3002
If the fetch fails
Fetch the first selected record from F3002
if (IXEFFF >= EffectiveFromDate and IXEFFF <= EffectiveThruDate) or
(IXEFFT >= EffectiveFromDate and IXEFFT <= EffectiveThruDate) or
(IXEFFF <= EffectiveFromDate and IXEFFT >= EffectiveThruDate)
Component Found = TRUE
If IXEFFF > EffectiveFromDate
RoutingEffectiveFrom = IXEFFF
Else
RoutingEffectiveFrom = EffectiveFromDate
End
If IXEFFT > EffectiveThruDate
RoutingEffectiveThru = IXEFFT
Else
RoutingEffectiveThru = EffectiveThruDate
End
WkUniqueID = WkUniqueID + 1
If IXFORQ = '%'
WkQuantity = IXQNTY/100
WkQuantity = WkQuantity*Cache Quantity
End
If IXFORQ = 'V'
WkQuantity = IXQNTY*Cache Quantity
End
If IXFORQ = 'F'
WkQuantity = IXQNTY
End
IXITM, WkUniqueID, IXCMCU, andWkQuantity
Branch = Branch
Third Item Number = ThirdItemNumber
BOM Quantity = WkQuantity
Fetch the next F3002 record
End
Use CacheFetch to get the next cache record
If ComponentFound = TRUE
Delete Cache records for previous level
Reset Cursor
End
WkLowLevelCode = WkLowLevelCode + 1
Delete all records from the cache
If Mode = 3
Destroy the cache
End
If any error occurs during a cache function
Set ErrorMessageID = '032E'
End
D3300100 - CRP, Create Resource Profile From BOM
Data Item Data Structure DescriptionI/ORequiredNotes
ITM Short Item Number IY
LITM Second Item Number IY
AITM Third Item Number IY
MCU Branch IY
ACQ Accounting Cost Quantity IY
EFFF Effective From Date IY
EFFT Effective Thru Date IY
MRYN Master Routing Flag IY
EV01 Mode I/OY 1 = Create Cache
2 = Process Item/Branch
3 = Destroy Cache
DSC1 Cache Name I/OY
SUPPS Suppress Error Message IY '1' = Suppress error
messages
' ' = Allow error messages
DTAI Error Message ID OY ' ' = success
'032E' = error processing the
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
| ||||
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
| ||||
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
| ||||
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
| ||||
cMasterRoutingFlag | 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
| ||||
cMode | EV01 | char | NONE | NONE |
An option that specifies the type of processing for an event. | ||||
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
| ||||
szCacheName | DSC1 | char | NONE | NONE |
Brief information about an item; a remark or an explanation. | ||||
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
|
B3300110 F3303, Create Resource Profile From Routing |
F3002 Bill of Material Master File |