Vous êtes sur la page 1sur 21

Automatic Rework Order using Reason of Variance Key

Applies to:
SAP Shop Floor Control (Production Orders) R/3 and ECC 6.0. For more information, visit the Manufacturing homepage.

Summary
This is an article explaining the use of reason of variance in production order confirmation in Rework Scenario. The entire necessary configuration, master data process and additional customer checks are explained in detail. Author: Santosh Sarda

Company: Accenture Services Private Limited Created on: 25 August 2010

Author Bio
Santosh Sarda has 5.5 years of rich experience in production planning area including 3.5 years of techno functional experience in SAP PP. Currently I am working with Accenture as SAP PP / QM Senior consultant.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 1

Automatic Rework Order using Reason of Variance Key

Table of Contents
Introduction ......................................................................................................................................................... 3 Scenario .............................................................................................................................................................. 4 Problem statement .......................................................................................................................................... 4 Solution ........................................................................................................................................................... 4 Rework Process steps .................................................................................................................................... 5 Configuration Settings ..................................................................................................................................... 5
Step 1 .......................................................................................................................................................................... 5 Step 2 .......................................................................................................................................................................... 6 Step 3 .......................................................................................................................................................................... 7

Customer Exit ..................................................................................................................................................... 8


Step1 ........................................................................................................................................................................... 8 Step2 ........................................................................................................................................................................... 8 Step3 ........................................................................................................................................................................... 9 Step3 ........................................................................................................................................................................... 9 Step 4 .......................................................................................................................................................................... 9 Step 5 ........................................................................................................................................................................ 10

Master Data ...................................................................................................................................................... 11


Step 1 ........................................................................................................................................................................ 11 Step 2 ........................................................................................................................................................................ 12 Step 3 ........................................................................................................................................................................ 13

Results. ............................................................................................................................................................. 14 Step 1 ............................................................................................................................................................ 14 Step 2 ............................................................................................................................................................ 15 Step 3 ............................................................................................................................................................ 15 Assumption: ...................................................................................................................................................... 19 Related Content ................................................................................................................................................ 20 Disclaimer and Liability Notice .......................................................................................................................... 21

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 2

Automatic Rework Order using Reason of Variance Key

Introduction
Rework is inevitable in any production process. Aim is to provide the perfect workable solution to handle the rework scenario in case of discrete manufacturing using production orders. This article explains use of Reason of variance key in production order confirmation to activate the user status on rework in production order. This user status in turn activates trigger point for creating rework order. This article also highlights how user exit can be used to add customer specific checks while order confirmation.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 3

Automatic Rework Order using Reason of Variance Key

Scenario
In standard SAP, There are different approaches to handle the rework, a) This can be done by creating a rework order with rework quantity posting in production order confirmation. b) Add reference operation sets for rework operations in the existing production order itself with rework quantity posting in confirmation. Both the above approaches can be implemented as below. 1. Handle rework automatically using trigger points in production order confirmation. This is useful if rework can be planned in advance based on your past experiences at certain operations in your production process. You can create a Rework order automatically or add Reference operation sets to existing production order operations automatically on rework quantity posting in confirmation. 2. Create a rework order w/o material manually in CO07 or add rework operations manually in existing production orders. This can be used to handle rework as and when it occurs. Rework costs can be collected in the rework order and finally can be settled to parent production order from where rework is generated. I will describe the automatic rework order creation using trigger points in detail. Problem statement In SAP trigger point can be executed with production order status change. For example changing the operation status to PCNF (Partially confirmed) during confirmation of order can trigger execution of a trigger point. In turn triggered point would facilitate creating a rework order or adding a new reference operation set to existing production order. However PCNF status of operation does not always means there is a rework at the said operation. We can have PCNF status of the operation in the scenarios where we post yield as and when produced or we post production activities as and when consumed. In short using production order system status to accurately implement the Rework handling using trigger point is not fool proof w/o further enhancement and customer exit checks. Also it is also observed that Standard SAP triggers Trigger Point execution based on operation status in the confirmation. When we are creating the rework order automatically, SAP does not ensure if rework quantity is entered in confirmation. Trigger point is executed based on only operation status and If Rework quantity is not entered still rework order is created with default quantity 1. Solution Implement rework scenario using Reason of variance key in confirmation. Via this key you can specify why a confirmed value deviates from a planned value (for example due to scrap, or due to an operating error). Reason of variance facilitates triggering a user status and in turn user status would execute the trigger point attached to the operation. It also helps to document the reason of the rework. This can also be achieved by setting the user status manually in the production order however Reason of variance would help in automating the process and handle the same at the time of posting rework quantities in confirmation itself. This would save lot of manual effort in Rework order creation process. User Exit CONFPP02 / CONFPP04 can be used to implement customer specific checks during confirmation. Here if reason of variance is entered for Rework then rework quantity is made mandatory in confirmation and vice a versa.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 4

Automatic Rework Order using Reason of Variance Key

Rework Process steps 1. Maintain required customizing and master data as described further. 2. Whenever rework is encountered, enter the Rework quantity and Reason of variance in CO11N confirmation screen. 3. Save the confirmation. User exit is triggered and customer checks are carried out. 4. Trigger point is executed and a rework order is created with rework operations and settlement to parent production order. 5. Once rework is complete, confirm the rework order for additional rework operations and excess components used in rework. NO GR will happen for rework order. TECO the rework order. 6. Cost incurred in rework will be settled to parent production order. 7. Do the GR and follow normal production order processing life cycle for Parent production order. Configuration Settings Step 1 Create / Change User Status profile: Create a user status profile with status RWRK and assign Production order header and operation as object types to this status profile. Transaction BS02

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 5

Automatic Rework Order using Reason of Variance Key

Step 2 Assign user status profile to order type definition: Path: SPRO->Production->SFC->Master Data->Order->Define Order type Transaction: OPJH:

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 6

Automatic Rework Order using Reason of Variance Key

Step 3 Define Reason of Variance: Define key Reason of variance in configuration of operation confirmation. Also assign the user status profile and status to this Reason of Variance key in the same transaction. Path: SPRO->Production->SFC->Operation->Confirmation->Define Reason of Variance Transaction: OPK5

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 7

Automatic Rework Order using Reason of Variance Key

Customer Exit
Activate User Exit: CONFPP02 Transaction: CMOD Step1 Create a new enhancement project: ZPPCO11.

Step2 Add Enhancement CONFPP02: Customer specific input checks1.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 8

Automatic Rework Order using Reason of Variance Key

Step3 Activate components under the Enhancement.

Step 4 Go to user exit include ZXCOFU12 and add customer specific checks with help of ABAPER.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 9

Automatic Rework Order using Reason of Variance Key

Text Elements in code:

Step 5 Activate the Include then enhancement and then Project.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 10

Automatic Rework Order using Reason of Variance Key

Master Data
Step 1 Create a standard trigger point in CO31

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 11

Automatic Rework Order using Reason of Variance Key

Step 2 Add a trigger point to routing operation where rework is expected in CA02.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 12

Automatic Rework Order using Reason of Variance Key

Step 3 Save routing and confirm trigger point is added correctly.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 13

Automatic Rework Order using Reason of Variance Key

Results
Step 1 Create a production order in CO01 and release the same for material JJ1000.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 14

Automatic Rework Order using Reason of Variance Key

Step 2 Check trigger point is copied to production order from routing.

Step 3 Post confirmation operation wise in CO11n (single screen confirmation) Operation 0010 is confirmed with yield of 25. Expected rework is to be posted at operation 0020. Case 1: Post a partial yield w/o Rework. Result: No Error, No trigger point execution. Post partial yield.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 15

Automatic Rework Order using Reason of Variance Key

Case 2: At operation 0020, Rework quantity entered but no Reason of variance entered Result: User Exit check is triggered to check the Reason of variance mandatory

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 16

Automatic Rework Order using Reason of Variance Key

Case 3: Reason of variance Entered but Rework quantity Empty Result: User Exit checks are triggered to check the mandatory rework quantity

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 17

Automatic Rework Order using Reason of Variance Key

Case 4: Post Rework of quantity 5 at operation 0020 with reason of variance as RWRK. Result: Trigger point is activated and rework order created.

Trigger point activated as shown below:

Confirmation is posted successfully and rework order created w/o material with rework quantity.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 18

Automatic Rework Order using Reason of Variance Key

Further rework is carried out based on this rework order. Activity and excess components are consumed against the rework production order. Finally once rework is done it is settled and cost is booked to parent production order.

Assumption:
1. For rework order Standard SAP order type PP03 is used, however it can be custom defines as per business needs. 2. For parent production order Standard SAP order type PP01 is used, however it can be custom defines as per business needs. 3. Creation of rework order without material is demonstrated below through trigger points. Same procedure applies for adding addition Reference operation set for rework in the same production order, only corresponding configuration of trigger point will change. 4. Required master data like material, routing, bom are already created for the production order header material.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 19

Automatic Rework Order using Reason of Variance Key

Related Content
SFC: Production Orders For more information, visit the Manufacturing homepage.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 20

Automatic Rework Order using Reason of Variance Key

Disclaimer and Liability Notice


This document may discuss sample coding or other information that does not include SAP official interfaces and therefore is not supported by SAP. Changes made based on this information are not supported and can be overwritten during an upgrade. SAP will not be held liable for any damages caused by using or misusing the information, code or methods suggested in this document, and anyone using these methods does so at his/her own risk. SAP offers no guarantees and assumes no responsibility or liability of any type with respect to the content of this technical article or code sample, including any liability resulting from incompatibility between the content within this document and the materials and services offered by SAP. You agree that you will not hold, or seek to hold, SAP responsible or liable with respect to the content of this document.

SAP COMMUNITY NETWORK 2010 SAP AG

SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com 21