Update Routings Using CP_BD_DIRECT_INPUT_PLAN
If using the CP_BD_DIRECT_INPUT_PLAN API provided by SAP, the following APIs are used in conjucntion with it:
/PTC/ZRFC_OPR_LABEL : Since the CP_BD_DIRECT_INPUT_PLAN API does not support operation label changes, /PTC/ZRFC_OPR_LABEL must be developed using BDC (Screen recording). This ZRFC then functions for operation label changes only.
RFC_READ_TABLE: This RFC is used to query the SAP table in order to fetch the group counter.
CSAP_MAT_BOM_READ: This RFC is used to query the component item ID in order to assign components to an operation.
BAPI_MATERIAL_GETALL: In cases of PRT allocation for the PRT with a category equal to M, it is mandatory to pass the unit of measure (UOM). The UOM is then queried using this BAPI.
CP_BD_DIRECT_INPUT_PLAN
If you decide to use the CP_BD_DIRECT_INPUT_PLAN approach, then use the following mapping structure to understand how Windchill attributes and TIBCO default and cross-referenced values are used to update a routing in SAP.
Windchill Attribute Name
API Structure
API Field
API Field Description
Value If Default Used
Source
Transform
RC271_DI_IMP
(General details)
TCODE
TRANSACTION CODE
TIBCO
Lookup
Start Date Effectivity
RC271_DI_IMP
STTAG
VALID FROM/KEY DATE
Windchill, if blank then TIBCO
Date function
Change number
RC271_DI_IMP
AENNR
ECN
Windchill
Process plan Distribution target : TargetID
RC271_DI_IMP
WERKS
Routing PLANT
Windchill
Substring function
Process plan number
RC271_DI_IMP
PLNNR
Routing Group number
Windchill Process plan number
RC271_DI_IMP
PLNAL
Routing Group Counter
TIBCO
Query from SAP
PLKO_DI_TAB
(Routing task list details)
ACTTYP
(ACTIVITY TYPE)
H – FOR CREATE
V – FOR CHANGE
L – FOR DELETE
“V”
TIBCO
PLKO_DI_TAB
PLNTY
Routing Type
TIBCO
Default lookup
ProcessPlan number
PLKO_DI_TAB
PLNNR
Routing group number
Windchill
PLKO_DI_TAB
PLNAL
Routing Group counter
TIBCO
Query from SAP
Start Date effectivity
PLKO_DI_TAB
DATUV
Routing valid from date
Windchill, if blank then TIBCO
Date function
Change number
PLKO_DI_TAB
AENNR
Change number
Windchill
Processplan category
PLKO_DI_TAB
VERWE
Routing usage (Task list usage)
Windchill
Cross references:
Lookup based on Process plan category
TargetID
PLKO_DI_TAB
WERKS
Routing plant
Windchill
Substring from Target ID
PLKO_DI_TAB
STATU
Routing status
TIBCO
Default Lookup
Base unit of measure
PLKO_DI_TAB
PLNME
Routing Unit of measure
Windchill
Cross reference : Lookup based on Routing base unit of measure
Lot
PLKO_DI_TAB
LOSVN
Lot size from
Windchill
PLKO_DI_TAB
LOSBS
Lot size to
TIBCO
Default lookup
Process plan Name
PLKO_DI_TAB
KTEXT
Routing description. (Task list description)
Windchill
Process plan part link
(Added or Deleted)
MAPL_DI_TAB
(Material allocation and de-allocation)
ACTTYP
H – FOR CREATE
L – FOR DELETE
TIBCO decides based on added or deleted Process plan part link
Part number from Process plan part link
MAPL_DI_TAB
MATNR
Material number
Windchill
If numeric then padding the part number.
TargetID of Process plan’s distribution target
MAPL_DI_TAB
WERKS
Routing plant
Windchill
Substring from TargetID
MAPL_DI_TAB
PLNTY
Routing type (“N”)
TIBCO
Default lookup.
Process plan number
MAPL_DI_TAB
PLNNR
Routing number
Windchill
MAPL_DI_TAB
PLNAL
Routing group counter
TIBCO
Query from SAP
Start date effectivity
MAPL_DI_TAB
DATUV
Routing valid from date
Windchill
Date function
Change number
MAPL_DI_TAB
AENNR
Change number
Windchill
Process plan operations (Added, changed or deleted)
PLPO_DI_TAB
(For operation and sub-operation)
ACTTYP
H – FOR CREATE
V – FOR CHANGE
L – FOR DELETE
TIBCO decided the flag based on added,changed, deleted operation
PLPO_DI_TAB
PLNTY
Routing type (“N”)
TIBCO
Default lookup
Processplan number
PLPO_DI_TAB
PLNNR
Routing group number
Windchill
PLPO_DI_TAB
PLNAL
Routing group counter
TIBCO
Query from SAP
Start date Effectivity of Process plan
PLPO_DI_TAB
DATUV
Routing valid from
Windchill, if blank then TIBCO passes current date
Change number
PLPO_DI_TAB
AENNR
Change number
Windchill
Operation Label
PLPO_DI_TAB
VORNR
Activity
Windchill
ERP validation code
PLPO_DI_TAB
STEUS
Control key
Windchill
Cross referenced : lookup based on ERP validation code
TargetID or plan from workcenterlink
PLPO_DI_TAB
WERKS
Operation plant or plant from Work-center
Windchill
Substring in case of TargetID
PLPO_DI_TAB
KTSCH
Standard Text Key
TIBCO
Default lookup
Operation Description
PLPO_DI_TAB
LTXA1
Operation short description
Windchill
Base unit of measure
PLPO_DI_TAB
MEINH
Operation unit of measurement
Windchill
Cross referenced: lookup based on Base unit of measure
PLPO_DI_TAB
UMREN
Nominator
1
TIBCO
PLPO_DI_TAB
UMREZ
Denominator
1
TIBCO
Quantity
PLPO_DI_TAB
BMSCH
Base quantity
Windchill
Work center number from Work center link
PLPO_DI_TAB
ARBPL
Work-center
Windchill
PLPO_DI_TAB
PLNAL
Routing Group counter
TIBCO
Query from SAP
Sequence Line number from the Operation holder
PLPO_DI_TAB
PLNFL
Sequence number (Standard, Alternate or Parallel)
Windchill
Operation label where Operation holder type is “OP”
PLPO_DI_TAB
UVORN
Sub-Activity (Sub operation label)
Windchill
Setup time
PLPO_DI_TAB
VGW01
Setup time
Windchill
Substring
Setup time
PLPO_DI_TAB
VGE01
Unit of measure for Setup time.
Windchill
Substring
Processing time
PLPO_DI_TAB
VGW02
Machine time (Processing time in Windchill)
Windchill
Substring
Processing time
PLPO_DI_TAB
VGE02
Unit of measure for Machine time
Windchill
Substring
Labor time
PLPO_DI_TAB
VGW03
Labour time
Windchill
Substring
Labor time
PLPO_DI_TAB
VGE03
Unit of measure for Labour time
Windchill
Substring
Waiting time
PLPO_DI_TAB
ZEILM
Max wait time unit
Windchill
Substring
Waiting time
PLPO_DI_TAB
ZALMX
Max. Wait time
Windchill
Substring
Queue time
PLPO_DI_TAB
ZEIWN
Standard queue time unit.
Windchill
Substring
Queue time
PLPO_DI_TAB
ZWNOR
Standard queue time.
Windchill
Substring
Move time
PLPO_DI_TAB
ZEITN
Standard move time unit.
Windchill
Substring
Move time
PLPO_DI_TAB
ZTNOR
Standard move time.
Windchill
Substring
Process plan sequences added, deleted or changed
PLFL_DI_TAB(For Sequences)
ACTTYP
H – FOR CREATE
V-FOR CHANGE
L – FOR DELETE
TIBCO decide based on added, changed or deleted sequence
PLFL_DI_TAB
PLNTY
Routing Type (“N”)
TIBCO
Default lookup
Process plan number from operation holder
PLFL_DI_TAB
PLNNR
Routing group number
Windchill
PLFL_DI_TAB
PLNAL
Routing group counter
TIBCO
Query from SAP
Start Date effectivity
PLFL_DI_TAB
DATUV
Routing valid from
Windchill
Date function
Change Number
PLFL_DI_TAB
AENNR
Change number
Sequence Category
PLFL_DI_TAB
FLGAT
SEQUENCE CATEGORY
2 (1 – PARALLEL; 2 – ALTERANTIVE)
Windchill
Cross referenced
PLFL_DI_TAB
BEZFL
REFERENCE SEQUENCE NUMBER
000000
TIBCO
Default lookup
Sequence Name
PLFL_DI_TAB
LTXA1
SHORT DESCRIPTION
Windchill
PLFL_DI_TAB
TXTSP
SHORT TEXT LANGUAGE
TIBCO
Default lookup
Process plan’s Lot size From
PLFL_DI_TAB
LOSVN
From Lot number
Windchill
Process plan’s Lot Size To
PLFL_DI_TAB
LOSBS
To Lot number
Windchill
Branch operation
PLFL_DI_TAB
VORNR1
Branch operation
Windchill
Return operation
PLFL_DI_TAB
VORNR2
Exit operation
Windchill
Added, changed, Deleted Consumable resource link (Resource allocation)
PLFH_DI_TAB
(PRT Allocation)
ACTTYP
H – FOR CREATE
V – FOR CHANGE
L – FOR DELETE
Windchill
PLFH_DI_TAB
PLNTY
Routing Type
TIBCO
Default lookup
Process Plan number
PLFH_DI_TAB
PLNNR
Routing group number
Windchill
PLFH_DI_TAB
PLNAL
Routing group counter
TIBCO
Query from SAP
Start Date effectivity of Process plan
PLFH_DI_TAB
DATUV
Routing valid from
Windchill
Change number
PLFH_DI_TAB
AENNR
Change number
Windchill
Sequence Line number
PLFH_DI_TAB
PLNFL
Routing sequence number
Windchill
For standard sequence : Default lookup
PLFH_DI_TAB
PSNFH
ITEM NUMBER
TIBCO
9000+position(), while deleting it should be fetched from SAP.
PLFH_DI_TAB
STEUF
CONTROL KEY
Windchill
Cross referenced
PLFH_DI_TAB
BZOFFB
REFERENCE DATE TO START OF PRT USAGE
TIBCO
Default lookup
PLFH_DI_TAB
BZOFFE
REFERENCE DATE TO END THE PRT USAGE
TIBCO
Default lookup
PLFH_DI_TAB
MGEINH
UNIT OF MEASURE
TIBCO
Query from SAP (For PRT Type =”M”) or default lookup.
Quantity at consumable resource link
PLFH_DI_TAB
MGVGW
QUANTITY
Windchill
Type and Category of the associated Resource,
Document link for operation
PLFH_DI_TAB
FHMAR
PRT TYPE/CATEGORY
Windchill
Cross referenced (M,E)
Process Plan plant
PLFH_DI_TAB
FHWRK
PLANT
Windchill
Resource number
PLFH_DI_TAB
MATNR
MATERIAL NUMBER
Windchill
Operation label
PLFH_DI_TAB
VORNR
OPERATION NUMBER
Windchill
Document type from Document link
PLFH_DI_TAB
DOKAR
DOCUMENT TYPE
Windchill
Cross referenced
Document number from Document Link
PLFH_DI_TAB
DOKNR
DOCUMENT NUMBER
Windchill
PLFH_DI_TAB
DOKTL
DocumentPART
TIBCO
Default lookup
Document version from Document link
PLFH_DI_TAB
DOKVR
DocumentVERSION
Windchill
Resource number from consumable resource link
PLFH_DI_TAB
EQUNR
EQUIPMENT NUMBER
Windchill
TEXT_OBJ_DI_TAB
(FOR LONG TEXTS)
NOTE: YOU MUST USE THIS TABLE ALONG WITH TEXT_DI_TAB
ACTTYP
H – FOR CREATE
V – FOR CHANGE
L – FOR DELETE
Windchill
“H” for Create operation
“V” for update operation”
TEXT_OBJ_DI_TAB
OBJ
OBJECT ( ‘O’ STANDS FOR OPERATION)
“O”
TIBCO
TEXT_OBJ_DI_TAB
PLNAL
GRP COUNTER
TIBCO
Query from SAP
TEXT_OBJ_DI_TAB
PLNFL
SEQUENCE
Windchill
Operation label
TEXT_OBJ_DI_TAB
VORNR
OPERATION NUMBER
Windchill
Sub Operation label
TEXT_OBJ_DI_TAB
UVORN
SUB OPERATION NUMBER
Windchill
Long description from operation
TEXT_OBJ_DI_TAB
TEXT_FROM
FROM LINE NUMBER
TIBCO
Long description from operation
TEXT_OBJ_DI_TAB
TEXT_TO
TO LINE NUMBER
TIBCO
TEXT_DI_TAB
TDFORMAT
FORMAT (*)
TIBCO
Long description from operation
TEXT_DI_TAB
TDLINE
LONG TEXT LINES
Windchill
PLMZ_DI_TAB
(FOR COMPONENT ALLOCATIONS)
ACTTYP
H – FOR CREATE
L – FOR DELETE
PLMZ_DI_TAB
PLNTY
Routing type (“N”)
TIBCO
Default lookup
PLMZ_DI_TAB
PLNNR
Routing group number
Windchill
PLMZ_DI_TAB
PLNAL
Routing group counter
TIBCO
Query from SAP
PLMZ_DI_TAB
DATUV
Routing valid from
Windchill
PLMZ_DI_TAB
AENNR
Change number
Windchill
PLMZ_DI_TAB
PLNFL
Routing sequence number
Windchill
PLMZ_DI_TAB
STLTY
BOM TYPE (M – MATERIAL BOM)
TIBCO
Default lookup
PLMZ_DI_TAB
STLNR
BOM NUMBER
Windchill
PLMZ_DI_TAB
STLAL
ALTERNATIVE
Windchill
PLMZ_DI_TAB
STLKN
ITEM NODE NUMBER
NOTE: AT RUNTIME, YOU WILL HAVE TO GET THE ITEM NUMBER BY USING the RFC: CSAP_BOM_READ.
TIBCO
Query from SAP
PLMZ_DI_TAB
WERK_STL
PLANT
Windchill
PLMZ_DI_TAB
STLTY_W
BOM TYPE (M – MATERIAL BOM)
TIBCO
Default lookup
Assembly Part number
PLMZ_DI_TAB
STLNR_W
BOM NUMBER
Windchill
Associated BOM alternate
PLMZ_DI_TAB
STLAL_W
ALTERNATIVE
Windhcill
Component number
PLMZ_DI_TAB
MATNR
MATERIAL NUMBER – THE COMPONENT OF BOM THAT YOU WANT TO ALLOCATE
Windchill
Associated BOM’s Distribution target
PLMZ_DI_TAB
WERKS
PLANT
Windchill
Component line number
PLMZ_DI_TAB
POSNR
ITEM NUMBER
Windchill
Component quantity
PLMZ_DI_TAB
MENGE
QUANTITY
Windchill
Component’s unit of measure
PLMZ_DI_TAB
MEINS
BASE UNIT OF MEASURE
Windchill
Assembly Part Number
PLMZ_DI_TAB
BOMAT
BOM’S NAME
Windchill
/PTC/ZRFC_OPR_LABEL
Windchill Attribute Name
API Structure
API Field
API Field Description
Value If Default used
Source
Transform
Change number
Import parameters
CHANGE_NUMBER
Change number
Windchill
Import parameters
FLAG
Flag whether to revert operation lable changes or not
“UPD” to update the operation lable (activity)
“REV” to revert the operation label change.
TIBCO
Import parameters
GROUP_COUNTER
TIBCO
Query from SAP
Process plan number
Import parameters
GROUP_NUMBER
Windhcill
Import parameters
KEY_DATE
TIBCO defaults to system date
Process plan associate distribution target
Import parameters
ROUTING_PLANT
Windchill
Substring
Sequence line number
T_OPR_LABEL
SEQUENCE_NO
Windchill
Old operation label
T_OPR_LABEL
OLD_OPERATIONID
Activity
Windchill
Operation label
T_OPR_LABEL
OPERATIONID
Activity
Windhcill
Sub operation label
T_OPR_LABEL
SUBOPERATIONID
Subactivity
Windchill
Old sub operation label
T_OPR_LABEL
OLD_SUBOPERATIONID
Subactivity
Windchill
Was this helpful?