BAPI_PRODORDCONF_CANCEL production order still blocked

Hi,
I have a problem when calling CO11N after BAPI_PRODORDCONF_CANCEL.
The error message displayed is: "Order XXXXX is already being processed by YYYYY".
It seems that when calling CO11N, the order still locked.
Below you can see an extract of my code:
CALL FUNCTION 'BAPI_PRODORDCONF_CANCEL'
            EXPORTING
              confirmation        = confirmations-conf_no
              confirmationcounter = confirmations-conf_cnt
            IMPORTING
              return              = ld_return
              locked              = ld_l
              created_conf_no     = created_conf_no
              created_conf_count  = created_conf_count.
IF ld_return-type <> 'E'.
         CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
            EXPORTING
              wait = 'X'.
ELSE.
          CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'.
ENDIF.
PERFORM bdc_transaction USING 'CO11N'.
i already read that the solution is wait, but  I don't want to code an ABAP instruction like:
WAIT UP TO 1 SECONDS.
after commit, because the BAPI can take longer than 1 second or 10.
I already tried the insctruction:
SET UPDATE TASK LOCAL.
before BAPI_PRODORDCONF_CANCEL. Unsuccessfully.
Does anyone have any experience with this BAPI? Is there any solution beyond WAIT instruction?
Thanks

How did you resolve the above issue ?

Similar Messages

  • Production Order Receipt Block before Usage Decision is Made

    Dear all,
    I have a requirement to block production order receipt through MIGO into any storage location before the usage decision has been made for that production order.
    This should be the rule for all non serial items, meaning that it should only apply to batch controlled and neither batch nor serial controlled materials.
    Could someone please help me on this?
    Thanks,
    Sergiy

    Hi,
    Is it possible through by maintaining the inspection type for the material master. Then the material will be moved to quality stock after usage decision then you can move that material to unrestricted material.
    For Batch managed or serial number profile defined material don't activate the inspection type.
    Hope this might help you.
    Regards
    Ravi shankar.

  • Production order released blocking the batch created

    Hello Guru,
    I have some question to ask, in production order, when we change the order via CO02, released it (production order create:classification) for batch will appear. after completing this the order "released carried out" will be the message. and when we save the order CHANGE BATCH view will display then, the production date and shelf life expiration date was automatically populated by SAP. my question is is there a possiblity that this CHANGE BATCH when will appear the production date and shelf life expiration date was unchangeble already SAP proposed date was fixed (gray-out) or instead change batch display batch will appear? is there any set-up to make this feasible?
    we want to block the production date/shelf life expiration date in modification once SAP has already computed and proposed this date for the batch on the FG material of the production order. Please help. I know this is a standard behavior, but can this be feasible?
    Any help or inputs.
    Thanks
    Edited by: Agent X44 on Mar 11, 2009 11:50 AM
    Edited by: Agent X44 on Mar 11, 2009 12:10 PM
    Edited by: Agent X44 on Mar 11, 2009 1:15 PM

    You must have to check batch Class and its characteristics. Something wrong here.
    Regards,
    RM

  • Duplicate production order due to sales order on credit block

    Dear Experts !
    Need feedback on the following scenario:
    - Sales order is entered for material which is produced in-house specific to the sales order (ie customer's logo is on product).
    - Schedule line in sales order creates a production order specific to the sales order.
    - Customer runs into credit check a few days later and consequently the schedule line in the sales order is removed due to credit block, however the linked production order still remains and is produced by factory.
    - Sales order is released from credit check and a new schedule line is created resulting in another production order being released.
    Any ideas on how to prevent duplication of production order?
    Thanks in advance!
       -Alvin

    Hello,
    Apologies for the confusion, let me explain it a bit more.
    - Sales order is entered for material with planning strategy group of make-to-order, the schedule line initiates new production order for make-to-order material.
    - A few days later - the customer goes over credit limit or has overdue invoices, etc..
    - During background rescheduling (or any sales order change) the sales order gets a credit block due to static check.
    - Sales order block deleted schedule line in sales order, however the production order remains active.
    - Once the sales order is released from credit block, a new schedule line is created which initiates a new production order.
    - Duplicate production order is now being made in shop floor.
    I hope the above explains my scnario a little clearer.
    Thanks and regards,
    Alvin

  • Block the production order creation till approval of sales order

    Dear
    We are using MTO process. Client is asking to avoid the creation of production order still the sales order is approved. In sales order one user status is defined as approved. By default when sales order is created the status will be in not approved and once the accounts clears, they manually change the status to approved. Is it possible to put system check  to avoid the production order creation till sales order status is changed to approved?? Any idea??.
    Thanks in advance.

    Dear Usmani,
    I'm facing the same problem as you. Do you already have the solution for this?
    As of now, the only solution to stop the transfer of requirement to MRP is to set the delivery block at the header level and also flag on the "Fixed Date & Qty" in each schedule line item. The problem is now to deflag the "Fixed Date & Qty" in each schedule line item when the Sales Order is confirmed.
    Please share should you have any other solutions.
    Thank you.
    Regards,
    Jieyi

  • Add inspection characteristics to production order created via CO07

    Hi, all.
    We're creating production orders to perform production rework on assemblies using transaction CO07. 
    We have a requirement to inspect and make a usage decision on the reworked assembly.
    Since there is no material at the header level for CO07 orders, the system isn't allowing us to do an inspection because it has no material master QA view to reference.  Although the control key is marked for in-process inspection, the production order still won't allow it.
    I can't add "unplanned inspection characteristics", not can I manually create an inspection lot using QA01. 
    Is there a way to manually force in an inspection for an operation on a CO07 order?
    Thanks.
    Sarah

    Hi,
    We cannot do a inspection for a production order unless it has material assigned to it and the material got QM inspection type relevant to that.
    regards,
    Lenin. A

  • Production Order confirmation part 2

    Hello,
    Thanks for the response on my last question,
    we want to confirm Production orders into Blocked stock, and I was informed that this was either a client change or we could use MIGO and so forth.
    Can we not assign Mvt Type 103 against a production order type?
    Thanks in advance.

    Guy,
    As sumit mentioned this setting is applicable for all the order types in PP, so not possible to define this for specific order type.
    Regards,
    Prasobh

  • To book a production-order as finish

    Hi,
    I have the problem that that our (obsolete)production-orders still appears
    in the dispo-list!
    Now I read, that the Controlling have to "book" the production order as
    finished (or similar else).
    In which transaction-code(CO) can I book orders as "finished"!

    Hello
    Check
    Scheduling margin key
    The float before production, float after production and the relea se period are defined in the scheduling margin key (Customizing for Shop Floor Control, by choosing Operations ® Scheduling ® Define Scheduling Margin Key) . The scheduling margin key is assigned to the material ( MRP area in the material master) and is transferred when the production order is created. These values can be changed in the production order.
    When is an order scheduled?
    When you create a production order it is always automatically scheduled. In the scheduling parameters (Customizing for Shop Floor Control by choosing Operations ® Scheduling ® Define Scheduling Parameters) you can define that, after every change relevant to scheduling, the production order is also automatically rescheduled before saving ( Automatic scheduling indicator) .
    reg

  • Production Order creation Despite Delivery Block on Sales Order

    Hi All
    I have created a Z1-Delivery Block and assigned the block to a Sales order type.
    Now during the creation of the Sales order the Delivery block is assigned immediately the system creates  a planned order but no production order.However the business would still like the production order to be created.
    Is there a SAP standard way to allow this to happen or would I need to enhance via a USER EXIT.
    Thanks in Advance for your assistance.
    KA

    I'm not an expert, but I don't think delivery block actually has any influence on the production order. We have tried on purpose to use a delivery block to prevent the PO creation/release and had to develop a user exit for this purpose. The way it works in our system - planned order has a conversion indicator. Some standard program runs in background and converts the planned orders with this indicator into the production orders. If indicator is not set then PO is not created.
    Delivery block just prevents delivery from PGI, I don't think it even prevents the delivery creation (much to my surprise).

  • How to block production order creation when maintenance order is generated.

    Hi All,
    Kindly share how to block production order generation when maintenance order is generated.

    Integration between PP module and PM module
    PP/PM Workcenter Integration
    There are many threads & documents available. Please do some search.

  • Blocking creation of production order if standard cost estimate is not done

    Hi PP gurus,
    Can anyone help me in blocking the creation of production order if the standard cost estimate is not done for the particular posting period.

    Hi,
    I do not think there exist a standart check. You can use exit EXIT_SAPLCOZF_003 to block creation of production order by sending error messages based on any condition.
    Regards.

  • Block Creation of Production order Unless released in Order.

    Hi Experts.
    we have a requirement where we want to block the creation of production order inless it is confirmed. Is there any User exit / or anyother indicator where i can define or configure so that the MRP run and also the Creation of the production order can be block for a sales order.
    Plz advice.
    Thanks in Advance
    Rishi

    Hi
    But Manually it does allow the user to create Production order .
    I want unless, Say the delivey block at item level is removed , User should not be allowed to create the production order for the relevant line item of the sales order.
    Any more suggestion
    Thanks
    Rishi

  • Block production order creation in MTO scenario when sales order is blocked

    Hello Experts,
    We are using the MTO scenario and creating production orders with refernce to sales order using CO08.
    The requirement is to not allow the creation of production order when the sales order has a block. It can be an overall block or a credit block.
    Right now the systme allows me to create the production order with refernce to the sales order even when the sales order is blocked.
    Is there any way by which this check can be activated.
    Thanks
    Ritesh

    Hi!,
    Please try follow:
    Go to path IMG > Plant Maintenance and Customer Service > Master Data in Plant Maintenance and Customer Service > Technical Objects > Serial Number Management > Define Serial Number Profiles. There enter "2" in Stkck column for your serial profile.
    Regards,
    Uday

  • Blocking of production order creation

    Hi All,
    I need a help on blocking of production order creation.
    I have few materials for which deletion has been activated in material master. But for these materials, while creating production order it is allowing to create by showing some warning message. But I want to totally block creation of production order.
    Regards,
    Vijay

    Dear,
    Youneed to define for block for productio.OMS4 --> create new one material status (08) for "Blocked for Prod Order" and set the prodution.
    If u want plant specific block then do not use this indicator in basic data 1 view ,use it in purchasing alse and MRP view.
    Please check with Message No M7-127 at OMCQ. Here u can set error message
    IMG>MATERIAL MANAGEMENT>INVEN>DEFINE ATTRIBUTES FOR SYSTEM MESSAGES. message no M7127
    Change the warning message to error. Then create the production order and check.
    Or Archieve material by SARA
    Regards,
    R.Brahmankar

  • Blocking of production orders

    Hi
    I'm trying to have production orders set with the "Blocked" status when a sales order is credit blocked. This is a MTO environment and as a default the system actually sets the "DLFL" status in such a situation.
    The problem with the standard setup is that the MRP run responds by generating a planned order. Once the credit block is removed the production order is reinstated however the planned order conversion, en mass, this results in a duplicate order.
    We wish to prevent this and setting the blocked status is, I think, the only way of achieving this.
    Does anyone know how to change the setting of the status?

    I feel, by removing the authorization(to users) to remove the Prod Order status for changing the status DLFL, your issue will be resolved (one way) of course, In this situation, Once the production order is set with status as DLFL, the production order will be no longer used. when ever, SO credit block removed, then next MRP run creates another planned order and which will be converted into production order for execution.(this is not the solution, you are expecting)
    On other side, check with Technical people, when 'credit block' is placed on SO, does the status DLFL is placed directly on Prod order (or) through some setting in SAP code. this issue, Technical experts can identify through debugging mode.
    hope this helps
    JK

Maybe you are looking for

  • Why do I get a program error when changing colors?

    I get a 'Could not complete your request because of a program error' when I try to change colors on both the forground/background palette or from the color picker palette.  Is there a patch for this? I am using Photoshop CS6 version 13.0.1.x64

  • How can I use Tags in Ical. Hope that it works like in finder

    Hi I am happy that OS 10.9 is suporting tags. Like to us it in Ical to keep it in sync with my taks used in finder. However I can not find Tag's in Ical and wonder if this is the same als Flag's. Can some help me out to keept it consistent troughout

  • Firefox 4 b7 gives a Profile Missing error when launching

    Firefox worked before on my OS X (10.6.5) system, but now gives a Profile Missing error that says "Your Firefox profile cannot be loaded. It may be missing or inaccessible." I can't launch the Profile Manager using the Terminal command. I tried putti

  • Electronic Signature is too small

    I have followed all the steps found but when I place my electronic signature on a PDF I have to squint to see it. Is there a way to blow up the size of my electronic signature?

  • To print transfer order by range

    Hi, I had 20 transfer order created and I would like to kick off the printing by selection on screen from TO#1 to TO#20. Is it possible to do so in LT31? There is a program, RLVSDR40 but it does not have any TCODE linked to it. Is there a standard TC