ME_REQ_POSTED

We are using BADI ME_REQ_POSTED (Purchase Requisition Posted which uses table EBAN & EBKN)  to compare old fields to new fields of the purchase requisition so that a field of an IDOC can be updated to identify that the purchase requisition has been changed.  However, BADI ME_REQ_POSTED, does not have the Service fields (ESLL and ESUH table values), therefore the program cannot compare the values of old values of table of ESLL & ESUH to new values of ESLL & ESHUH for a purchase requisition.  User is making changes to the Service Purchase Requisition via transactions ME52N & ME53N (change).  Does anyone know of a BADI or BAPI that will execute prior to the changes being saved to a Service Purchase Requisition that will update an IDOC field that will identify that the service data (ESLL & ESUH) has been changed on a purchase requisition?    Thank you.

Hi,
please check instead if the note 1094119 could help you to solve your problem.
Regards,
Edit

Similar Messages

  • Help Needed in badi ME_REQ_POSTED

    Hi all
    Actually i wanted to modify the release code IM_EBAN-FRGZU based on some conditions using BADI(ME_REQ_POSTED)
    But its not allowing me to do it..its saying IM_EBAN can't be modified...
    I tried ME590001 - EXIT_SAPLME59_001 aslo but its not stopping either in ME54 or ME55.
    Could you please give me the alternate solution to modify the release status while in the transaction?
    Thanks
    Govi

    Hi Govi,
    try this one:
    EXIT_SAPLMEPI_003                Customer Exit for Changing Purchase Requisition Data
    Regards,
    Clemens

  • Changing data captured via ME52N through BADI - ME_REQ_POSTED not working!

    Hi All,
    I am trying to change the 'Release Date' value everytime some data is changed on a purchase requisition via transaction ME52N.  I am using BADI 'ME_REQ_POSTED' via my own implementation of interface method 'IF_EX_ME_REQ_POSTED~POSTED'.
    Everything works and I can access all the data that I need except the fact that the standard variables with item data (i.e. 'IM_EBAN') cannot be changed and so I am forced to rather change table EBAN directly by using a 'MODIFY' statement after processing the data within the BAdi method.
    However when I check table EBAN via se16 I find that the field that I want to change (i.e. EBAN-FRGDT) does not change at all even though the transaction states that the document has been saved successfully and my BADI implementation has been executed in full.
    Therefore how can I ensure that the field is updated via this BADI or via a direct update within the BAdi implementation?
    Thanks.

    Hi,
    I have solved this one.
    Thanks.

  • Purchase Requistion (ME51N) : BADI ME_REQ_POSTED

    Hi,
            I have used ME_REQ_POSTED-post(Method) Badi to check custom consistency in ME51N. If there is any error the badi throws the Message and returns to t-code : using leave to transaction  sy-tcode which is working fine, but the problem is that even the creation of the PR is manually stopped the PR number is generated and not saved(say: 8000012). Next time when I am creating a new PR with the same consisentcy check and if it gets through a new  number is generated with (say 8000013) but not with (8000012).If this case araises there will be problem with number range allocation each and every time they get exhausted?
    Kindly post the solution if any one has ever faced.....
    Thanks in advance for the help.
    with regards,
    krishna Mukthineni.

    Hello Krishna
    Most likely you are not using the correct BAdI. As the name implies (ME_REQ_POSTED) we have passed the last checkpoints already. The method IF_EX_ME_REQ_POSTED~POSTED is not intended to block the posting since it does not contain any exceptions.
    I assume that BAdI ME_PROCESS_REQ_CUST is the one you should implement. Its interface method CHECK ( Closing Check ) allows you to block saving the purchase requisition. If you set its CHANGING parameter CH_FAILED = 'X' then saving should not be possible.
    Regards
      Uwe

  • Regarding the BADI ME_REQ_POSTED after saving the tcode ME51N

    Hi,
    Currenlty i am using the badi ME_REQ_POSTED to update the header texts in ME51N while creating the PR.
    I am getting the PR number through IM_EBAN.
    My issue is that i have written the code in the badi to pass the input of that PR number in table RSDBS to get the reservation number.
    But once the transaction ME51N got saved, then only the table RSDBS is getting updated with the generated PR number.
    Is there any way to get updates of the table RSDBS before the transaction got saved.
    Please let me know if my question is not clear.
    Thanks & Regards.
    Prabu

    Hi,
    I don't think this is possible functionally? To achieve this, you need to modify the std code.
    Regards,
    Raj

  • Can Me_REQ_POSTED (in ME54) be used to modify custom fields in EBAN?

    Hi ,
    I have a requirement that I have to validate the approver authorization when he tries to approve the PR. I am using the badi ME_REQ_POSTED and the method is 'POSTED'. I have created a z implemetation including this method and the validation are working fine, But at the same time I need to update some custom fields while this check in the BADI.
    I have tried BAPI_PR_CHANGE, direct using update statement but still unable to update the custom fields in EBAN TABLE.
    I have noticed that at point of update custom field is  getting updated but when later on the release status gets updated from the system my custom field value also vanishes.

    After BAPI you need to use CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    Are you using it?
    Apps

  • ME_REQ_POSTED , unable to modify?

    hi all,
    i am creating PR from PS using tcode: CJ20N and i need to update PR customised fields, unfortunately, whatever fields i change in badi  ME_REQ_POSTED , it is not changing PR data, can anybody explain why?
    i cannot use other PR badi as creation  from PS does not call other badi

    Hi,
    This should do the trick :
    CALL FUNCTION 'BAPI_REQUISITION_GETDETAIL'
      EXPORTING
        NUMBER                               = it_display-banfn
    *   ACCOUNT_ASSIGNMENT                   = ' '
    *   ITEM_TEXTS                           = ' '
    *   SERVICES                             = ' '
      TABLES
        REQUISITION_ITEMS                    = it_requisition_items_old
    *   REQUISITION_ACCOUNT_ASSIGNMENT       =
    *   REQUISITION_TEXT                     =
    *   REQUISITION_LIMITS                   =
    *   REQUISITION_CONTRACT_LIMITS          =
    *   REQUISITION_SERVICES                 =
    *   REQUISITION_SRV_ACCASS_VALUES        =
    *   RETURN                               =
    read table it_requisition_items_old index 1.
    move-corresponding it_requisition_items_old to
                       it_requisition_items_old2.
    move-corresponding it_requisition_items_old to
                       it_requisition_items_new.
    it_requisition_items_new-des_vendor = lifnr.
    append it_requisition_items_old2.
    append it_requisition_items_new.
    CALL FUNCTION 'BAPI_REQUISITION_CHANGE'
      EXPORTING
        NUMBER                        = it_display-banfn
      TABLES
        REQUISITION_ITEMS_OLD         = it_requisition_items_old2
        REQUISITION_ITEMS_NEW         = it_requisition_items_new
    *   REQUISITION_ACCOUNT_OLD       =
    *   REQUISITION_ACCOUNT_NEW       =
    *   REQUISITION_TEXT_OLD          =
    *   REQUISITION_TEXT_NEW          =
    *   RETURN                        =
    Regards,
    Dirk.

  • ME_REQ_POSTED save BADI to create PO

    Hi Friends,
    I have a requirement. Once the PR created. Immediately PO should get created.
    I am trying to use the BADI ME_REQ_POSTED. In the run time, i am getting the PR number and am using it to create PO. But it is throwing error as PR does not exist.
    Please can u suggest any other way that we can create PO automatically once the PR created.
    Thanks & Regards,
    Prabu

    Hi Prabu,
            If you want to create PO automatically when PR is created then follow these.
    1. PR should be assigned to a vendor and
    2. in the material master the Auto PO check box must be selected (have check mark).
    Additional settings shall be made:
    1) The source list shall be maintained and in the event we have had more than one suppliers for a certain material, then the 'fixed' indicator shall be ticked on the most preferable vendor.
    2) The 'Auto PO' checkbox shall also be ticked on the Vendor Master Data.
    Hope this would be helpful for you.
    Regards,
    Supriya.

  • Badi ME_REQ_POSTED

    Hello,
    I've found this badi but i'm unable to change anything. IM_EBAN and IM_EBKN are like constants...
    I guess there are methods to get data and to save them just like in the po :
      CALL METHOD im_item->get_data
        RECEIVING
          re_data = re_data.
    Do you have any code example of an implementation of ME_REQ_POSTED that will help me know what to do.
    Thanks in advance
    Points will be given if usefull
    Jean-Michel

    Hi Jean-Michel,
    with the BADI ME_REQ_POSTED  you can't modify the that.
    You can make some checks but not modify.
    Try to use the ME_PROCESS_REQ_CUST.
    There are different methods, problably PROCESS_ITEM one can help you.
    Bye
    enzo

  • Badi ME_REQ_POSTED  For CJ20N Transaction

    Dear All,
    I am creating PR from PS using tcode: CJ20N and i need to check PR Requisitioner fields through CJ20N ,
    I am able to give error message for PR Requisitioner field through BADI ME_REQ_POSTED . My problem is as follows
    Suppose First time I enter wrong value (Ex. ABC ) in Requisitioner field , then it gives error message, then I give correct  Value (Ex. 1101_003 ) in Requisitioner Field  At that time also it is giving the error message.
    When I give correct value in Requisitioner Field the new value of Requisitioner is not coming in IM_EBAN
    I need to check every time latest value of Requisitioner Field in IM_EBAN in CJ20N.
    Following code I have written in IF_EX_ME_REQ_POSTED~POSTED
    IF SY-TCODE = 'CJ20N' .
        C_ATINN = 'PR_REQUISITIONER'.
        CALL FUNCTION 'CONVERSION_EXIT_ATINN_INPUT'
          EXPORTING
            INPUT  = C_ATINN
          IMPORTING
            OUTPUT = C_ATINN.
        LOOP AT IM_EBAN INTO L_S_EBAN WHERE LOEKZ IS INITIAL.
          CLEAR W_AFNAM.
          SELECT SINGLE ATWRT  INTO W_AFNAM
              FROM CAWN WHERE ATINN = C_ATINN
                          AND ATWRT = L_S_EBAN-AFNAM.
          IF SY-SUBRC <> 0.
            MESSAGE E499(SY) WITH  'Invalid requisitioner'
          ENDIF.
        ENDLOOP.
      ENDIF.
    Already searched on SDN.
    Please help me why the latest value which we enter in requisitioner is not coming in IM_EBAN
    Thanks in Advance
    Regard's
    Shabbir
    Any Help !!!
    Edited by: Shabbir Kureshi on Jul 15, 2010 1:01 PM
    Edited by: Shabbir Kureshi on Jul 15, 2010 2:08 PM

    Hello Shabbir
    If I understand you correctly then you want to prevent the creation of a purchase requisition in case of an invalid Requisitioner.
    In this case I would assume that BADI ME_REQ_POSTED is the wrong one because BAdI method implies that the PR will be saved. Why?
    There is no exception (not usual for BAdI methods) nor a CHANGING parameter like CH_FAILED defined.
    I assume that the correct BAdI for your purpose would be ME_PROCESS_REQ. Final checks BEFORE saving the PR are implemented in interface method IF_EX_ME_PROCESS_REQ~CHECK.
    In case of failure you set CH_FAILED = 'X'. In order to set an error message you may have a look at the following coding:
    METHOD if_ex_me_process_req~check .
      INCLUDE mm_messages_mac.
      DATA: ls_mereqitems        TYPE MMPUR_REQUISITION_ITEMS,
            ls_mereqitem         TYPE MMPUR_REQUISITION_ITEM,
            l_mereqitem          TYPE mereq_item,
            l_msgty              TYPE sy-msgty,
            l_msgno              TYPE t100c-msgnr.
    *-Get the item data
      ls_mereqitems = im_header->get_items( ).
    *-Get the configuration of the messages from T100S
      l_msgno = '173'.
    *-Check if the PR date is in the future
      LOOP at ls_mereqitems into ls_mereqitem.
        l_mereqitem = ls_mereqitem-item->get_data( ).
        CHECK     l_mereqitem-badat > sy-datlo
        AND   NOT l_msgno IS INITIAL.
        CALL FUNCTION 'READ_CUSTOMIZED_MESSAGE'
          EXPORTING
            i_arbgb = 'FICUSTOM'
            i_dtype = '-'
            i_msgnr = l_msgno
          IMPORTING
            e_msgty = l_msgty.
        IF 1 = 2.
          MESSAGE w173(ficustom). "WHEN POSTING
    *    MESSAGE w170(ficustom). "WHEN HOLDING
        ENDIF.
        IF NOT l_msgty = '-'.
          IF l_msgty = 'E'.
            ch_failed = ' '.
          ENDIF.
          sy-msgno = l_msgno.
          mmpur_message l_msgty 'FICUSTOM' sy-msgno
          l_mereqitem-bnfpo space space space.
        ENDIF.
      ENDLOOP.
    ENDMETHOD.
    Regards
      Uwe

  • BADI ME_REQ_POSTED in Transaction ME55

    Hi all,
    I'm trying to implement BADI ME_REQ_POSTED to prevent users releasing purchase requisitions in transaction ME55 which they created themselves.
    I've got the code below to work to a certain extent, an error will be displayed when you click on one of your own requisitions, however, if you then click the 'release' button of a requisition which wasn't created by you, both documents are released.
    I have a feeling that this is due to the releasing function not being complete when the error message is shown, so it continues when the second requisition is clicked, validating both documents. I'm very new to ABAP so open to any suggestions!
    method IF_EX_ME_REQ_POSTED~POSTED.
      if sy-tcode = 'ME55'.
        DATA: ls_header TYPE UEBAN.
        loop at im_eban into ls_header.
        endloop.
        if ls_header-ernam = sy-uname.
          MESSAGE ID 'ZVAL' TYPE 'E' NUMBER '010'.
        endif.
      endif.
    endmethod.
    Thanks,
    Richard

    Hi Richard,
    Did you find solution to your problem?I have nearly same problem too.
    If you find,can you tell the solution you find?
    Thanks

  • Error Handling in ME_REQ_POSTED BADI

    Hello Gurus,
    I have to display an error message in ME51N and ME52N.
    I am using the BADI ME_REQ_POSTED to do that.
    My problem is that my error is type E .
    After this error is correctly displayed I am unable to change any field values as all the fields are grayed out. How do I change any values after this error message.
    I am using type E error because I do not want user to save the transaction with error values. But I want to allow user to make changes after the error message is displayed.
    Thanks

    Hi,
    You can through the status message instead of error msg and try to keep the control in the transaction.
    message s000(ZMSG).
    leave to screen sy-dynnr.
    message s000(ZMSG).
    so that the control will be in the transaction and yiou can modify the fields as well.
    With Regards,
    Dwarakanath.S

  • Update tracking number through : BADI ME_REQ_Posted

    HI ALL,
    greetings.
    i had a query .
    i have to update the table EBAN and update the field
    tracking number(EBAN-BEDNR)at the line item level in the
    TCODE : ME52N.
    i have already generated a number through number range .and want to populate the tracking number and subsequently update table EBAN at SAVE Button of ME52n.
    you can find the field tracking number at the line item under the tab contact person in the tcode me52n.
    i would appreciate any help from ur side
    thanks in advance.
    Gaurav.

    Hello Gaurav,
    Try using user exit 005(EXIT_SAPLMEREQ_005) which is fired for each item. U can incorporate ur logic to generate the tracking number in this exit.

  • How to update the table available in BADI method

    Hi Friends,
    I have to implement one badi ME_REQ_POSTED for purchase requistion, in this badi  I have to read first line item and do
    some check...if that check is true i need to update subsequent line item (line 20, 30, 40 or so) with purchase group and MRP controller.
    In this BADI i have method POSTED, in this method parameter IM_EBAN is a table which i need to modify with my different
    values for purchase group and MRP controller.
    Kindly let me know how to update this table, so the changes can be reflected in purchase requistion.
    Since when I tried to directly modify the table in a loop, system throw one error stating IM_EBAN can not be modified.
    kindly help.
    pradeep

    hi
    I have implemented this exit but it does not stop at it while saving Purchase requistion. But my previous BADI stops at it when saving.
    Kindly guide.

  • Problem in BADI, error message not getting displayed

    Hello Experts,
    I am facing a strange problem in BADI.
    The requirement is that the user should not be allowed to change the plant field
    on the screen of standard MM transctions for PO/PR amendment.
    I have written the code in separate BADIs for PO and PR.
    I am displaying an error message if the user tries to change the field.
    For PO, it is working fine.But for PR, the same code is not working.
    The control is going over to the BADI for PR and rest of the code is working fine.
    But the error message is not getting displayed for PR amendment.
    Can anybody please suggest the possible cause of problem and some solution to it.
    Thanks in advance.

    Hi
    See the sample BADI code for PR which raises an exceptions and do accordingly
    BAdI Name: ZPUR_RFQ (Implementation name) Purchase Requisitions
    Definition Name: ME_REQ_POSTED
    Interface Name : IF_EX_ME_REQ_POSTED
    Implementing Class: ZCL_IM_PUR_REQ
    Method :            POSTED
    METHOD if_ex_me_req_posted~posted .
      DATA : v_mtart TYPE mtart.
      DATA l_s_eban TYPE ueban.
      LOOP AT im_eban INTO l_s_eban.
        IF l_s_eban-estkz NE 'B'.
          CLEAR v_mtart.
          SELECT SINGLE  mtart INTO v_mtart FROM mara WHERE matnr = l_s_eban-matnr.
          IF v_mtart EQ 'ZERS' OR v_mtart EQ 'FHMI' OR v_mtart EQ 'UNBW'.
            MESSAGE e000(zm_msg) WITH 'You are not allowed' 'to create PR for stock items'.
          ENDIF.
        ENDIF.
        IF  l_s_eban-knttp NE 'F' OR l_s_eban-pstyp NE '9'.
          IF l_s_eban-knttp NE 'A'.
            IF ( l_s_eban-pstyp NE '9' AND l_s_eban-pstyp NE 'D' ) 
               AND l_s_eban-matnr EQ space.
              MESSAGE e000(zm_msg) WITH 'You cannot create'
                'a PR without material number'.
            ENDIF.
          ENDIF.
        ENDIF.
      ENDLOOP.
    ENDMETHOD.
    <b>Reward points for useful Answers</b>
    Regards
    Anji

Maybe you are looking for

  • Error while activating IM in CFM2

    Dear Friends, I would like to have a solution to the folowing problem. I've tried to activate integration models in ECC with transaction CFM2. I've build several integration models for class, customer, masterdata and transaction data. When I try to a

  • Copy from clipboard and paste in Web Dynpro table

    Hi I have a client requirement where the client wants to copy the table from some already existing application and paste the data  directly in web dynpro java table.  It is similiar to copy the data from clipboard and paste it directly in web dynpro

  • Query -suggest me

    Hi Experts         I am using the following query, my input as 'ZSO' only, but now the query is not working properly. what could be the reason. pls help me on this. SELECT a~aufnr        a~plnbez        a~dispo        b~kdauf        b~kdpos        c~

  • CJS-00091 Unable to create the tablespaces

    Hi while installing database instance in ecc5.0 i am aslo getting the same error. ERROR 2006-12-11 15:11:42 CJS-00091 Unable to create the tablespaces. DIAGNOSIS: There is not enough free disk space: Mount point | space required | space available | S

  • Temporary Variables

    I’m sure there’s an easy solution to this and that I must be looking at it the wrong way.In my calc script, I’ve created a temporary variable called BC_uf_wages containing the following members. My actual outline for the “urban fare” has many members