Problem in Purchase requisition change BAPI

Hi Techies
When using BAPI  "BAPI_REQUISITION_CHANGE" for AFS for changing the purchase requistion,   the changes are getting affected only in the purchase request line item level.  whereas the schedule line (AFS size Breakup)  is not getting changed.
CALL FUNCTION 'BAPI_REQUISITION_CHANGE'
          EXPORTING
            number                         = va_prno
          TABLES
            requisition_items_old          = it_itmold
            requisition_items_new          = it_itmnew
      REQUISITION_ACCOUNT_OLD        =
      REQUISITION_ACCOUNT_NEW        =
      REQUISITION_TEXT_OLD           =
      REQUISITION_TEXT_NEW           =
            return                         = it_return
            requisition_afs_data_old       = it_liold
            requisition_afs_data_new       = it_linew.
        IF sy-subrc = 0.
          CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
            EXPORTING
              wait = 'X'.
          CLEAR: flg.
        ENDIF.
please suggest.
Regards,
PRASAD.

Hi,
Yes, in the AFS BAPI these parameters are exits..
ofcourse,i got the Solution..
Best regards
Prasad.EV

Similar Messages

  • Problem in Purchase Requisition Upload

    Hi all,
    I am uploading Purchase Requisition through BAPI
    by BAPI_REQUISITION_CREATE.
    Then I am appending text both in items and header by
    fm CREATE TEXT.
    But when i am uploading the item text
    Line Comments are transfering with the extra characters.
    example:-
    When we type long descriptions we use returns and blank lines for formatting.  Right now the text is coming over but the formatting is getting messed up.( The Blank lines and return are getting messed with # .)
    how to solve it.
    thanks in advance.
    SG

    Hi ,
    One suggestion it may work try out..
    i think the problem is with the formatting input to the create_text function module. try to change the import parameter  of the function module CREATE_TEXT i.e FFORMAT to initial.

  • Problem in Purchase Requisition Creation

    Dear Experts:
    We are facing a problem while purchase requisition creation. We have created an Internal order No. 600406 and an Asset in Company Code AB01 but while creation of Purchase Requisition level when we are selection that Order and Asset in Purchase Requisition system automatically changing my Order no. 600020 instead of 600406. I've checked OKB9 where Order no. maintained as 600020 against Company code AB01 which I deleted and save but after that Purchase requisition asking for Order Number that means we have to maintain Order number in OKB9. Now can you please advise how can we get my current order number in requisition instead of any default number.
    Thanks in advance and your kind suggestion is highly appreciated.
    Best Regards.
    Ripon Kumar Paul

    Please find attached screen shots of OME9

  • Problem in purchase requisition release strategy code

    Hi
    We are facing a problem in purchase requisition, a new release strategy was created and change request transported but when PR is displayed in release strategy chart a same user is showed in different release strategy code.
    Note: new strategy was copied from other.
    Thanks in advance.

    hi,
    As you said tht you have copied the release stategy n created the new one...
    If you do so, you would have copied the class also...to which the release group is attached...
    If this is the case, then system doesn't recognise the new one, and inorder to solve it you have to define the new characteristic and class...then assign this class to the release group and make your release strategy again...
    Once you do this check the release strategy at OMGSCK...and then try at PR...
    You do all settings at :
    SPRO >> IMG>> MM >> Purchasing >> PR >> define release strategy >> W/o classification >> here edit characteristics/class and all other link are provided...
    Regards
    Priyanka.P

  • Creation of Purchase Requisition using BAPI

    Hi Experts
    Can anyone provide me the sample code for creating Purchase Requisition using BAPI
    Thanks in advance

    Hi siri,
    go throught this, hope
    http://www.erpgenie.com/abap/bapi/example.htm
    Also refer to the following links..
    www.sappoint.com/abap/bapiintro.pdf
    www.sap-img.com/bapi.htm
    www.sap-img.com/abap/bapi-conventions.htm
    www.planetsap.com/Bapi_main_page.htm
    www.sapgenie.com/abap/bapi/index.htm
    Checkout !!
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    http://sap-img.com/bapi.htm
    Thanks
    Naveen khan
    Message was edited by:
            Pattan Naveen

  • Create Purchase Order with reference to Purchase Requisition using BAPI's

    Hello Experts,
    I need to create a Purchase order with reference to a Purchase Requisition.
    All the above has to be done by using BAPI's.
    For creating PR, I am using BAPI_REQUISITION_CREATE.
    and for PO, I am using BAPI_PO_CREATE.
    I am not able to use the requistion number in the PO. BAPI throws the following exception
    "Requisition 1014396 00010 not selectable"
    "Document contains no items"
    Query's:
    1. Do I need to release the PR for using it in PO?
    2. If so how can I work with the "BAPI_REQUISITION_RELEASE_GEN" to release PR?
    I have tried using the BAPI getting the following error "Release outside filed of responsibility".
    Please help I am in critical Postion...
    Thanks,
    Suma

    Hi Meenakshi,
    When, I try to release error I am getting the following the error " Purchase Requisition can not be released".
    Is this problem because of authorization or data issue?
    Thanks
    Suma

  • Purchase requisition change

    Hi Experts,
    I need a report for a purchase requisition, if a PO already exists against it, I need to change the flag for the purchase requisiton as closed. Is there any sample report to do this?I have checked BAPI BAPI_REQUISITION_CHANGE. Do I need to also use the GETDETAIL bapi before using this.
    Please advise.
    Thanks,
    Raj

    Is the sales order a third party order?
    What did you change in sales order?
    What want you change in PR ?
    Do you get an error or why do you ask?
    If you got a message, which one? Double click the message and post the message number here.

  • Purchase Requisitions Change after create existing document.

    Hi,
    We want to restrict System not allow to change the Purchase Requisition Quantity after create the existing document RFQ & PO with reference of PR.
    Regards
    Aamir

    Dear Amir,
    We had also faced same problem in our organization 2 years back. Then I have change the screenlayout of ME52N as follows.
    SPRO -> Materials Management -> Purchasing - > Purchase Requistion -> Define screeen layout at document level -> Create new entry ME52N by coping ME52. Then goto qty & price field, tick the Qty field as display.
    Due to this changes in PR Qty in ME52N will not be possible. If any change in PR QTY before creation of PO has to be done then user has to delete that line item in ME52N & create new line item in same PR.
    This development is successful at our end.
    Regards,
    Shekhar Gaikwad.
    SAP MM Consultant

  • ME52N: Purchase Requisition Change GL Account Number

    Requirement: ABAP auto-change the GL Account field number in a Purchase Requisition after the Material Group is changed.
    Background: This custom logic has been successfully applied to all types of Purchase Requisitions using  BADI ME_PROC_REQ_CUST, with the exception of a Purchase Requisition type that is called a 'Service Limits'. There are differences that are important to note between a 'Service Limits' Purchase Requisition and the other Purchase Requisitions that had custom code added without any problems.
    1)This type of Purchase Requisition uses a item category of 'B', and the logic has a tendency to flow through SAP differently.
    2)This type of Purchase Requisition's GL Account number is under-intensified on the 'item' subscreen, and cannot be changed manually on that screen like the others..
    3)In order for the GL Account to be changed manually, or for the GL Account to be changed once my code has changed the GL Account Number, the user must select the 'Limits' tab and select the Account Assignment arrow, then a popup appears where the GL Account can be changed manually, or, my coded GL Account number change then occurs.
    Problem: I want the custom code to be able to change the GL Account NUmber without having to go into thge 'Limits' tab, where the icon has to be selected. I believe the problem is that the field is protected, because it displays as under-intensified, thus, preventing my new GL Account NUmber from displaying. I also have the subsequent SAP code below that appears to reject set_exkn because protect is set to 'X'.
    CODE1: Is my custom code.
    CODE2: Is the SAP code that my will flow into where this field appears to be unchangeable.
    My question:
    I am thinking that this GL Account field is protected and cannot be changed because it is under-intensified on the subscreen on the Purchase Requisition. Can it be changed with custom code, a way to 'unprotect it'? Or, are there settings that should be changed in SPRO for the Purchase Requisition to allow this functionality to change the GL Account number.
       Thank-You
    (CODE1)
    METHOD IF_EX_ME_PROCESS_REQ_CUST~PROCESS_HEADER.
    *Purchase Requisition Item Declarations
      DATA: LT_ITEMS        TYPE MMPUR_REQUISITION_ITEMS.
      DATA: LS_ITEM         TYPE MEREQ_ITEM.
      FIELD-SYMBOLS: <FS_ITEM> TYPE LINE OF MMPUR_REQUISITION_ITEMS.
    *Purchase Requisition Accounting Declarations.
      DATA: LT_ACCT         TYPE MMPUR_ACCOUNTING_LIST.
      DATA: LS_ACCT         TYPE EXKN.
      DATA: LS_SETX          TYPE MEPOACCOUNTING_DATAX.
      FIELD-SYMBOLS: <FS_ACCT> TYPE LINE OF MMPUR_ACCOUNTING_LIST.
      CALL METHOD IM_HEADER->GET_ITEMS
        RECEIVING
          RE_ITEMS = LT_ITEMS.
      LOOP AT LT_ITEMS ASSIGNING <FS_ITEM>.
        LS_ITEM = <FS_ITEM>-ITEM->GET_DATA( ).
        LT_ACCT = <FS_ITEM>-ITEM->IF_ACCT_CONTAINER_MM~GET_ITEMS( ).
        LOOP AT LT_ACCT  ASSIGNING <FS_ACCT>.
          LS_ACCT =  <FS_ACCT>-MODEL->GET_EXKN( ).
          LS_ACCT-SAKTO = 'N500300   '.
          LS_SETX-SAKTO = 'X'.
          <FS_ACCT>-MODEL->SET_EXKN( LS_ACCT ).
          <FS_ACCT>-MODEL->SET_EXKNX( LS_SETX ).
        ENDLOOP.
      ENDLOOP.
    ENDMETHOD.
    (CODE2)
    METHOD if_accounting_model_mm~set_exkn.
      DATA: ls_buffer     LIKE LINE OF my_data_input_buffer,
            ls_bufferx    LIKE LINE OF my_data_input_bufferx,
            l_buffered    TYPE sy-subrc,
            l_data_old    TYPE exkn,
            l_data_oldx   TYPE mepoaccounting_datax,
            l_data_newx   TYPE mepoaccounting_datax,
            l_indx        TYPE sy-tabix.      "1478013
      *PROTECT EQ 'X'
      CHECK my_state->protect EQ mmpur_no.
    Edited by: Tom Matys on Dec 12, 2011 10:55 AM

    Your PO release strategy must have been based on Cost Center as one of characteristics.
    Pl check & confirm.
    Regards
    Bhavesh Mistry

  • Purchase order referencing released purchase requisition change

    Hello everybody
    When we create a purchase order making reference to a released purchase requisition, I can still make changes on the item such as changes on the quantity, value, etc.
    We would like to know how to restrict changes of purchase orders when they reference purchase requisitions already released.
    Thank you in advance and regards,
    Alejandra Álamo B.

    Hi,
    For meeting this requirement, you will have to create a new document type (If the same requirement exists for all the Purchase Orders, do not create additional document types).
    Next create a new Field selection where the fields that are copied from PR are made non editable (display). Assign this field selection to the new document type.
    Normally, PO fields are editable because the quantity and values may change based on the negotiation with vendor, or to club requirements.
    Hope this helps
    Priyadarshi

  • Problem with purchase requisition interface via SAP XI

    Hello.
    We are integrating the purchase requisition from external aplication to SAP through SAP XI. SAP XI send a IDOC to SAP R3 to create the purchase document. The conection is made with rfc conection which has set the comunication user and logon language. The purchase requisition is created with the logon language and if the material has not short text in this language in material master the error ME095 is generated.
    I don't understand this error because in the interface we set the PR short text which is posible to change. Also, we have set this system message like warning in T160M.
    We don't find any way to skip this message and we think if the interface allow to set a short text in the PR it's the same that the material master isn't updated with the short text in logon language.
    Thank you very much.
    Alberto

    Hi.
    I don't want to change the short text in Material Master. I only want to change this short description in PR, but if I don't mantain the short description in material master the error ME095 is generated. I need to be able to create a PR independent of logon language.
    Thank you for your answer.
    Alberto

  • Problems with purchase requisition interface via SAP XI

    Hello.
    We are integrating the purchase requisition from external aplication to SAP through SAP XI. SAP XI send a IDOC to SAP R3 to create the purchase document. The conection is made with rfc conection which has set the comunication user and logon language. The purchase requisition is created with the logon language and if the material has not short text in this language in material master the error ME095 is generated.
    I don't understand this error because in the interface we set the PR short text which is posible to change. Also, we have set this system message like warning in T160M.
    We don't find any way to skip this message and we think if the interface allow to set a short text in the PR it's the same that the material master isn't updated with the short text in logon language.
    Thank you very much.
    Alberto

    Hi.
    I don't want to change the short text in Material Master. I only want to change this short description in PR, but if I don't mantain the short description in material master the error ME095 is generated. I need to be able to create a PR independent of logon language.
    Thank you for your answer.
    Alberto

  • Problem in Purchase Requisition Number Range (Skipping)

    Hi,
    While creating the Purchase Requisition, the PR Number is skipping by 10, for example, first PR is 10000000, send is 10000010 and so on.. on the Quality Server
    The same is OK in Development Server. Pls. note that I have used the Standard Number Range.
    Pls. guide.
    Regards,

    Hi,
    To add on Arun's answer. The setting in trs SNRO is client independent. You should press the "display" button there (the glasses) and check the field "No. of numbers in buffer". The standard SAP setting is 10 and changing this setting is a modification to standard.
    The scenario is as follows. Each time your application server needs to allocate new number to a PReq it contacts the database server, which keeps track of the number range. Even if your system (Q) is a single server system, the principle is still the same.
    The point is that the application server doesn't take one next number from the database server, but 10 numbers. Next time it needs to allocate new number to a PReq, it doesn't have to call the DB server again - it merely takes the next number from the "bundle" it already got. The reason is to save time.
    This works fine as long as the application server is up and running all the time - no "holes" are generated. It can however happen that the application server "forgets" the buffer, e.g. when the server is taken down (this is however not the only way). In this case, all the numbers it got from the DB server get lost and the application server takes out new ten.
    As I mentioned above, this function is impossible to change without modification to SAP standard. Please consider well your business need to have the consequent numbers. Most of the companies manage with this setting.
    BR
    Raf

  • Bom explosion in purchase requisition using BAPi

    Hello All,
    Is it possible to explode a BOM in a purchase requisition using a functional module.
    Vivek

    Rajen,
    I have a material on which when I run MRP I get purchase requisitions with two different production version.
    In one purchase requisition I can see the BOM components and while on the other one I dont see BOM components.
    If I pass these two Purchase requisitions in EBAN table I find that RSNUM is blank for the latter case.
    If I go in this purchase requisition in change mode and explode the BOM and save, I can see BOM components.
    Also If I refresh EBAN table after this activity, I see the RSNUM field is populated.
    I hope this helps.
    Vivek

  • Problem in Purchase Requisition Release Strategy

    Hi sapgurus,
                           i am defining a release strategy for Purchase Requisition. but whenver in a strategy two release codes are incorporated suppose
    Release group :MM
    Release Codes: M1 and M2.
    but in relese simulation tab showing
       "M2   Release prerequisite missing"
    and M2 code is not working in releasing pr.only M1 is worked.
    Thanks in advance.
    Regards,
    Bipasha

    Actually I want to create two release strategy
    1. when total value in PR will be 1000.00 then one person can release PR.
    2. when value is greater than  1000.00 then two persons will release.
    For this i created a release group K1 with checkbox against  'OvRelPReq'  is ticked.Then i have created M1 and M2 release codes are created.
    Then I have given release indicator one for realesed and another for not released.
    After that , create a relase strategy
    where after M1 ,M2 can able to release the PR.in prerequisite button i ticked the checkbox near M2.
    It will not work.
    Plz give me a suggestion.

Maybe you are looking for

  • Wrong direction of Packet loss

    Recently,I capture some RTP packets when user meeting the dialogue jitter and latency. User A using the 3951 ip phone (IP address is x.x.125.206, and x.x.200.165 is the voice gateway's ip address ) , and user B using a mobile phone. User A responds t

  • Keeps coming up as a error while trying to upload

    I have been uploading files in the past to Acrobat.com but it appears the larger the files the more difficult it is on some occasions, 2 in particular last night. I think some, maybe 2 or 3 may have been too large for the page, out of lets say 149 do

  • What do I have to do in order to record without the headphones on my laptop?

    I am trying to record my voice on my MacBook Pro. But the computer only recognizes my speech when I use the external microphone from my headphones. I tried using Garage Band and it did not pick up any sound, I even opened Skype to do a test call and

  • Setting the classpath of classes12.zip for Tomcat

    Hi I am using Apache Tomcat webserver and while trying to run a jsp page which intializes oracle.jdbc.driver.OracleDriver it throws an error java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver Please suggest how to set the classpath of

  • Security questions issues!

    My daughter has topped up her iTunes account with vouchers for Xmas, she has gone to use them and it has asked for her security questions. This is where the problems starts, she has forgotten the answers! After a few tantrums from her.... and me I do