What's the name of FM for getting Sales Order Header / Item Status info

Hello All:
Do you know what's the name of Function Module for getting Sales Order Header / Item Status Overview ? Any sample code will be very much appreciated.
Basically, I am trying to create a Webpage where user can enter the Sales Order document number and will return the Sales Order: Status Overview.
Thanks,
Dipankar Biswas

Thanks everybody ! Appreciate for your prompt response. I was also looking for some sample code, and I did find some on. And here is one. I still have to try the code, but here is for all your reference:
*& Report ZBAPI_SALESORDER_GETSTATUS *
*& Read and Display the Sales Order Items and Status of the Order *
REPORT zbapi_salesorder_getstatus NO STANDARD PAGE HEADING LINE-SIZE 200 LINE-COUNT 33(3).
TABLES: vbap. "Sales Document Item Data.
DATA: wa_bapireturn TYPE bapireturn,
wa_bapisdstat TYPE bapisdstat,
it_bapisdstat LIKE STANDARD TABLE OF wa_bapisdstat.
TYPES: BEGIN OF ty_mat_name,
matnr TYPE makt-matnr,
maktx TYPE makt-maktx,
END OF ty_mat_name.
DATA: wa_mat_name TYPE ty_mat_name,
it_mat_name LIKE TABLE OF wa_mat_name WITH KEY matnr .
PARAMETERS: p_vbeln LIKE vbap-vbeln DEFAULT 5573.
START-OF-SELECTION.
SELECT matnr maktx FROM makt INTO TABLE it_mat_name.
CALL FUNCTION 'BAPI_SALESORDER_GETSTATUS'
EXPORTING
salesdocument = p_vbeln
IMPORTING
return = wa_bapireturn
TABLES
statusinfo = it_bapisdstat.
IF wa_bapireturn IS INITIAL. " Successful Execution.
WRITE: / 'Document No: ' COLOR 1, 20 'PO Number : ', 40 'Status' , 50 'Delv.Stat',60 'Item No', 80 'Material', 90 'Material Description', 130 'Net Price' COLOR 2.
ULINE.
LOOP AT it_bapisdstat INTO wa_bapisdstat.
WRITE: / wa_bapisdstat-doc_number. " Sales Document Number.
READ TABLE it_mat_name INTO wa_mat_name WITH KEY matnr = wa_bapisdstat-material.
WRITE: /20 wa_bapisdstat-purch_no, " Customer Purchase Order Number
40 wa_bapisdstat-prc_stat_h, " Processing Status
50 wa_bapisdstat-dlv_stat_h, " Delivery Status
60 wa_bapisdstat-itm_number, " Item Number
80 wa_bapisdstat-material, " Material
90 wa_mat_name-maktx, " Material Description
130(10) wa_bapisdstat-net_price. " Net Price
CLEAR wa_bapisdstat.
ENDLOOP.
REFRESH it_bapisdstat[].
ELSE.
WRITE: wa_bapireturn-message.
ENDIF.

Similar Messages

  • What is the standard class used to create SALES ORDER in SAP CRM?

    Hello Experts,
    Can anyone suggest me what is the standard class used for creating sales order.
    I have created sales order using the BAPI 'BAPI_SLSTRANSACT_CREATEMULTI' in my report program.
    Now, I have to create sales order using standard classes and methods(my assignment).
    Please suggest the suitable class.
    Regards
    DNR Varma

    Hi Varma,
    You can create crm documents like sales order using BOL interfaces.
    You can check one example at the following thread:
    Create OrderThro BOL
    Check if it helps you a little more.
    Kind regards,
    Garcia

  • How to create a sap script for sales order header items?

    Hi friends i am totally new to scripts i have got a task where i have to create a sap script for sales order header items details, the clue that i have got is to create using MEDRUCK but i have got no idea please can any body help me with this task with any sample sap script?
    Points will be rwwared with out fail Thks in advance.

    Hi,
    The Standard Form NAme is RVORDER01
    Regards
    Sandipan

  • Creating multiple partner function for a sale order @ header level

    Hi All,
    I have a requirement where in i have to create more than one partner funtion for a sale order @ header level. But the system did not allow this sort of scenario and i got the error,
    Partner function ZZ can only occur  1 times in procedure TA (Sales Document Header)
    the function module that was giving this error was SD_PCHECK_PARVW_COUNT_OK
    here the function module checks if a partner function already exists if so it throws that error. This also updates the VBPA table where partner function is one of the key fields.
    Our issue is that we have to allow the system to enable posting 2 or more partner function for the same sale order. It was also verified that the unique key was unchecked during configuration.
    is there any other way of over coming this issue as we are updating the standard table. Is it possible??
    Thanks a lot in advance for your reply....

    I believe this is a configuration setting, based upon the details of your post.  Typically, a sales order can have multiple partner functions, but usually the partner type is not duplicated at a single level (header or one item).  For example, it would not be logical to have multiple ship-to partners at the header level...these would be unique at the item level, if required.
    Speak to your SD functional specialist about the configuration controls for partners, if you must have more than one partner with parvw = ZZ, for the entire order (header level).
    Edited by: DaveL on Aug 23, 2011 3:00 PM

  • Select aentries from table Z-Table for all sales order line items

    Hi friends,
    can anyone please explain me about the "Select entries from table Z-Table for all sales order line items".
    Thanks.

    Moderator message - Welcome to SCN.
    But
    Moderator message - Please search before asking. Press F1 on SELECT and look at the FOR ALL ENTRIES addition. - post locked             
    Rob

  • Custom program for availability check and update for existing sale order at Item level(VA02)

    Hi,
    I came to know Bapi_Saleorder_Simulate can be used for availability check and update an existing sale order.but there is no sample program explaining the process.I have tried this by passing parameters ORDER_HEADER_IN , ORDER_ITEMS_IN  ,ORDER_PARTNERS and ORDER_SCHEDULE_EX(for getting details),also i have assigned the sale document number ,custom document type(ZSO) in ORDER_HEADER_IN . while executing the BAPI I am getting the error external number range is not assigned for the document type ZSO . I am confused on seeing this error. It is possible to do availability check for existing sale order using this BAPI. Please explain how to achieve this.It will be really helpful if it is expalained with an example.   
    Regards,
    Shanmuga

    Hello, I think you may have been misinformed about this BAPI updating a sales order at item level. As far as I understand it this BAPI can be used to simulate the creation of a sales order which obviously would include and ATP check. This is why it is giving the error because it is simulating creation but you are entering a value in a field that should be automatically generated (i.e. the sales order number). For change the sales order at item level have you looked at BAPI_SALESORDER_CHANGE? I pretty sure this BAPI both updates sales order (header or item level) and can do an ATP first.
    Points are always welcome if you feel an answer has been helpful.

  • How to update the sales order header & item data in TM system

    Hi Experts,
    Greetings!
    I need your help,I have a one requirement sales order data came from ECC these sales order data need to update in TM Sales order header table as well as item table also these fields are additional fields.
    Can anyone please guide me I am very new in TLM .
    Thanks in advance.
    Thanks&Regards,
    Siva.

    Hi Siva
      "/SCMTMS/TRQ~ROOT" is for sales order header and "/SCMTMS/TRQ~ITEM" is for details.
      I assume you need to
    enhance the structures for these nodes to hold your add. fields;
    and do the same for the input parameter of service TransportationRequestRequest_In (which is used to create OTR) from PI side;
    Pass the add. fields during service call (impelment in ERP system);
    Map the fields from service paremeter to node attribute (implement in TM system, BAdI   /SCMTMS/TRQ_SE_TPNRQ_REQ~CHANGE_MODIFICATION create modification table for the input parameter).
    I cannot find source code for all of that; hope it helps.
    Sensen

  • Reading the block message or text from sales order header.

    Dear All,
    Please let me know how to read the block text which is present in the sales order header under texts tab.
    thanks in advance
    regards,
    Shoban

    HI
    Please look intothe follwoing code, which helps you to understand how to read the header slaetext.
      DATA: BEGIN OF text_head.
              INCLUDE STRUCTURE thead.
      DATA: END OF text_head.
    DATA: BEGIN OF TEXT_LINES1 OCCURS 10.
          INCLUDE STRUCTURE TLINE.
    DATA: END OF TEXT_LINES1 .
    DATA: text_id     LIKE thead-tdid     VALUE '0001'.
      DATA: text_spras  LIKE thead-tdspras   VALUE 'EN'.
      DATA: text_name   LIKE thead-tdname.
      DATA: text_object LIKE thead-tdobject VALUE 'VBBK'.
    CALL FUNCTION 'READ_TEXT'
          EXPORTING
            client                  = sy-mandt
            id                       = text_head-tdid
            language                = text_head-tdspras
            name                    = text_head-tdname
            object                  = text_head-tdobject
          TABLES
            lines                   = text_lines1
          EXCEPTIONS
            id                      = 1
            language                = 2
            name                    = 3
            object                  = 5
            reference_check         = 6
            wrong_access_to_archive = 7
            OTHERS                  = 8.
        CASE sy-subrc.
          WHEN 1. RAISE invalid_id.
          WHEN 2. RAISE invalid_language.
          WHEN 3. RAISE invalid_name.
           WHEN 4. RAISE NOT_FOUND.
        ENDCASE.

  • Sales order line item status for an item with PR

    Hi Gurus,
                  Here is my business scenario.
    i have got following list of line items in a sales order.
            Line item no        Material no       Order quantity     Schedule line confirmed qty     Line item overall status           Plant
                    10        A                    3                              3                                   Open                         X
                    20        B                    5                              5                                    Open                        X
                     30        C                    8                              0                                    Open                        X
    1. I can create delivery for the line tiem 10 & 20 as they are confirmed for schedule lines.
    2. Line item 30 is not actually available in Plant X now if i do the availability check and select another plant "Y" where the material is available. For this STO should process should follow up (Correct me if i am wrong)
    Now i have got following questions
    1. How can i track which line items are followed up by PR's and which are not in the sales order.
    2. tell me how follow up happens by creating PR's
    Thank you

    1. So i am assuming that for each schedule line item there will be associate PR number and PO number if there are any.
    Yes every non stock article will have a associated PO.
    2. Suppose if Purchasing department make a decision to get this line item thru 3rd party then what happens for this schedule line item.I mean how do we differentiate in showing Sales order? Here my scenario is one Material can get thru either STO or thru 3rd Party.
    If you have more than 1 vendor listed for an article in EINA table. Then at that point the system will prompt you to select the vendor you want to create the PO against. (Given that the regular vendor flag is not checked for any vendor).
    Eg: Suppose if i have a schedule line item which can get thru STO and i have got another schedule line item which i can get thru 3rd party, Can i see this differentiation in sales order?
    3. How to create purchase requisition?
    Tcode Me21n (Advise to use this tcode) or ME21
    Found a link hope this helps
    http://www.le.ac.uk/mis/docs/sapdocs/mm/mm46b_41.doc

  • Changing the Ship-to partner details in Sales order header through exit

    Hi all,
      I have a requirement where in during the process of the sales order creation, based on certain
      criteria, the details in the ship-to partner would have to be modified.
      These details like the Name, Street, etc would be maintained in a local table and based on the criteria,
      the appropriate record from this table would be fetched and updated to the ship-to partner.
      I was trying to implement this in the MV45AFZZ user exit. However, I was not able to update this through the exit.
      Would I have to somehow update the ADRC table directly through this exit or is there any better method.
      Please suggest.
    Regards,
    Sudeep

    Hi,
    If you could not find Street in this Routine call the BAPI BAPI_BUPA_ADDRESS_CHANGE to update Street and required details ..
    Thanks and regards,
    Sree.

  • Suppresing Delivery note prints for certain sales order types/item category

    Hi
    I need to find a way of suppressing some delivery notes from being printed.
    Relating to orders for consignment fill up and consignment issue.
    The delivery notes are needed to be printed for 'Consignment fill up order' type, BUT not for Consignment issue - as this is confusing some of the warehouse staff at month end.
    All have the same delivery type, the only difference i can see is the item category types are different
    Is there a way i can use the sales order type, with customer number as an access sequence for the Output type ?
    -  Or the Item category type ?
    Is it possible to add sales order type or Item category into the FIELD CATALOG :- output for deliveries
    Your help would be much appreciated
    Cheers
    Tony

    Hi,
    I can suggest you something, but do remember that I've never done such kind of thing till date.
    >> Copy LF and create new delivery type
    >> Assign this to your consignment doc. types
    >> Kindly remove the Header output determination procedure assigned to this new delivery type
    >> Then assign output det. procedure at Item level {according to Item category}
    >> Then check if will cater to your requirment or not.
    Please keep one thing in mind that I am giving you a proposal by thinking in one logical way and I can't confirm the practicality of the proposal.
    Hrishi

  • Routine for copying sales order header text to invoice

    Hi friends,
    My requirement is to copy header texts from sales orders when creating an invoice (VF01). In T-Code VOTX the system suggests two routines :
    1 - DATEN_KOPIEREN_01 include LV45TE01
    2 - DATEN_KOPIEREN_02 include LV45TE02
    Does anyone already use one of these routines? When invoicing more than one sales order does the routines work fot this case ?
    Best Regards.

    Hello.
    .....goto transaction VOFM
    Menue: Copying requirements -> Billing documents
    ...or maybe: Data transfer -> Billing documents
    Put a break-point and the header routine......for long-text you should use transaction VOTXN
    Edited by: Erik Hoven on Feb 24, 2009 12:28 PM

  • How to Find Out The Production Order Number For The Sales Order Line Items

    Hi All,
    I want to know the number of production orders for each sales order line item. I know the sales order number .Can anyone tell me how the tables can be linked to get all the production order numbers for each sales order line item.

    I think it depends on your configuration. But check fields KDAUF and KDPOS in table AUFK.  or in table AFPO.
    Regards,
    Rich HEilman

  • BAPI for return sales order

    Hi,
    what BAPI that can be used for Return Sales Order? BAPI SALES_ORDER_CREATEFROMDAT2 cant work, I get return message as error : 'Unpermitted combination of business object BUS2032 and sales document type category H'.
    thanks alots.
    Alia

    Hi Alia,
    Go to transaction BAPI, and in the tree go to :
    Sales and Distribution -> Sales -> SalesOrder
    You will have a list of all the BAPI for the Sales Order. If you want a list of Sales Order, maybe you need the GetList BAPI : BAPI_SALESORDER_GETLIST
    Rgd
    Frédéric

  • Sales order line item delete error for MTO sales order

    Dear Experts
    iam facing below error for MTO sales order line item deletion
    "For reasons of cost management, item 000040 cannot
    be deleted"
    Please help
    Regards,
    KEdar

    It looks you try to delete the sales order line item and you get this error message.
    Try to put reason for rejection for the line item and save the order. This is equal to deleting the line item.
    You can also refer the OSS note 14097 - Order item cannot be deleted/overwritten for further information.
    Regards,

Maybe you are looking for