Skip to Content
Personal Insights
Author's profile photo Pooja Yadav

How to handle repair production order in SAP Digital Manufacturing Cloud(DMC)

In this blog, I would like to show how to handle repair production orders in SAP Digital Manufacturing Cloud(DMC).

                                                                  Repair production orders are created to correct the defects. Such orders will be without the reference to material so that labor cost will capture only. Currently DMC, supports the order with valid material number but to capture labor hours on repair Order, material may not be needed. So, such order without the material will get failed in DMC. In this blog, you will see a way to handle repair orders in DMC.


  1. Create a dummy material in DMC.
  2. Modify the Production Orders (LIOPRO05 V2) custom XSLT to accept the order without material in Manage Integration Workflows app in DMC.

Creating a dummy Material in DMC

  1. Go to Manage material app.
  2. Click “+” to create new material.
  3. Manage%20Material%20AppUnder Main section, filled all the mandatory fields.
  4. Under Alternate UOM section, add UOM
  5. Under Build section, make sure Order Processing Mode field have “Use ERP and Routing (Default value)” value.
  6. Click save.
  7. Dummy material is created.


Modifying Production Order Custom XSLT to accept the production order without material

We must modify in the below nodes in XSLT, so that DMC accept the order without material-

  1. Node : ManufacturingOrder => Material
        <!---Added for rework order|Header Material-->
            <xsl:when test="MATNR">
                <xsl:value-of select="MATNR"/>
                <xsl:variable name="material" select="'NULL_ECC'"/>
                <xsl:value-of select="$material"/>
  2. Node : ManufacturingOrder ==> BillOfMaterial
    <!-- Added for Rework Order | Bill of material Number-->
        <xsl:when test="MATNR">
            <xsl:value-of select="STLNR"/>
            <xsl:variable name="BillofMaterial" select="'02110817'"/>
            <xsl:value-of select="$BillofMaterial"/>
  3. Node : ManufacturingOrder ==> BillOfMaterialVariant
        <!-- Added for Rework Order | Bill of material Variant-->
            <xsl:when test="MATNR">
                <xsl:value-of select="STLAL"/>
                <xsl:variable name="BillofMaterial" select="'1'"/>
                <xsl:value-of select="$BillofMaterial"/>
  4. Node : ManufacturingOrder ==> BillOfMaterialVariantUsage
        <!-- Added for Rework Order | Bill of material Variant usage-->
            <xsl:when test="MATNR">
                <xsl:value-of select="STLAN"/>
                <xsl:variable name="BillofMaterial" select="'1'"/>
                <xsl:value-of select="$BillofMaterial"/>
  5. Node : ManufacturingOrder ==> MfgOrdPlndTotQtyInBaseUnit (if missed this, you will not able to release the order).
    <MfgOrdPlndTotQtyInBaseUnit pp:unitCode="{BMEINS}">
        <!-- Added for Rework Order | Planned Quantity-->
            <xsl:when test="MATNR">
                <xsl:value-of select="BMENGE"/>
                <xsl:value-of select="GAMNG"/>
  6. Create new </pp:ManufacturingOrderComponent> node for when order doesn’t have material.
    <!--Added for Rework Order | Generating Bill of material payload with hardcoded values -->
    <xsl:if test="not(E1RESBL) and not(string(/LOIPRO05/IDOC/E1AFKOL/MATNR))">
                <xsl:value-of select="PRVBE"/>
            <RequiredQuantityInBaseUnit pp:unitCode="GLL">1</RequiredQuantityInBaseUnit>
                <xsl:value-of select="LGNUM"/>
                <xsl:call-template name="convertToBool">
                    <xsl:with-param name="bool" select="BACKFLUSH"/>
                <xsl:call-template name="convertToBool">
                    <xsl:with-param name="bool" select="KZKUP"/>
                <xsl:value-of select="SOBKZ"/>
                <xsl:call-template name="convertToBool">
                    <xsl:with-param name="bool" select="ALPOS"/>
                <xsl:value-of select="ALPGR"/>
                <xsl:value-of select="ALPST"/>


Now let’s create a repair production order in ECC and release it to DMC.


  1. Creates a repair order.
    • Go to CO07 tcode  (create order without material).
    • On the Header screen, make following entries Order Text (Enter PO number and material Component Number for reference)-
      • Quantity (repair qty)
      • Base Unit of Measure
      • Finished Date of Order
    • Now on the Maintain Settlement Rule: Overview screen, Enter following fields-
      • Cat
      • Settlement Receiver
    • Then go to Operation Overview, Update Work Center as Repair work center in the operation details where the repair operation is carried out with standard values.
    • Now in the Component Overview check that no components are exists.
    • Release order by clicking release button and save.
    • Production Order for Repair is created.


  1. Go to integration Message Dashboard, check order is successfully created.
  2. Go to Manage orders, click on “Release”, and release the order.
  3. Use Work center POD, to execute and complete the repair order on the assigned work center and resource.



In this blog, you learned how to handle the repair production orders and to transfer the order without a header material to DMC. The order can be released in DMC to perform operations using work center POD.

*Thanks to my teammate – Swanand Joshi



Do you like this post? Please let me know in the comments section what you think. Any feedback is highly appreciated.

Or, if you have any questions, please check SAP Community Q&A Area, or comment down below.

To know more about the SAP DMC solution, see here.



Pooja Yadav

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Michael Koerner
      Michael Koerner

      Thank you for this blog! It's great and I will share it with interested DMC customers.

      I have some questions: How does the system behave at the end of the process?

      As the order is flagged as ERP-Order, the Goods Receipt message will probably be triggered, but the dummy material is unknown to the ERP. So, do you always have failed message for this scenario?

      And did you check the Floor Stock handling? Will there be two distinct inventory IDs? One for the faulty product and now one for the dummy product?

      Currently, you are not able to continue the Product History of the original SFC (and its logged nonconformance codes), but we're planning to provide an API that will allow to reassign the original SFC to this new repair order.

      Thanks again for this good writeup and the extensive XSLT examples.

      Author's profile photo Santhi Tiyyagura
      Santhi Tiyyagura

      I agree with Michael that there are many loose ends with this solution like not connecting the recieved floor stock to the repair production order and creating dummy material which is unknown to the ERP.

      In my previous engagement, we proposed a better solution to this Repair/Refurbishment orders.

      While creating an order in tcode CO07, we maintained a separate order type for Repair/Refurbishment orders and provided the Material number in material Description.

      Enhanced LOIPRO XSLT such that it reads Material number from MATX field which is description if order type is Repair/Refurbishment.

      Then add the floor stock id/serial number if you are doing GR with serial number under the serial tab on production order in MES.

      we can use pre xslt enhancements, to stop sending conf on a single operation when a product ID cycling multiple times between a standard operation and rework.

      Then on releasing the order it created inventory ID same as that added serial number above so we don't loose the genealogy.

      Now the repair order is created for the header material and it has serial number if it has to reserialized and to be recieved in ERP by consuming the old serial number