Upload file and link to sales order in SAP via rfc (C#)

Hello all,
In my company we have the possibility to attach files to sales orders, e.g. pdf files with the printing details.
These files are added by the GUI user, this works fine.
Now we have an extra order creation stream in which a pdf file has to be added to the SO without user interaction.
In a previous question I had a little question about the linking, that has been solved, I will post the test program later.
I now can link front end files (pdf's in this case) to the sales orders and it works fine.
Now we are developing a frontend in C# (build by a third party) which creates a sales order via a RFC. We also want that RFC to include the PDF file and link it to the created order.
In the interface of the RFC I included a table with 255 char lines. That is the same as in the example program. the problem is that our partner is yet unable to fill the interface in exact the same way as the example program does, so the linked pdf file is corrupted.
Does anyone have hints how C# should fill the interface table, or how I can change the interface?
code snippid table declaration for pdf table:
IT_PDF     LIKE     ZETEX_TAB_PDF
and
structure ZETEX_TAB_PDF consists of
LINE     CHAR255
the sample program (see other topic on where I got it)
REPORT  zzfb_brc LINE-SIZE 260.
* Report  Z_RMTIWARI_ATTACH_DOC_TO_BO
* Written By : Ram Manohar Tiwari
* Function   : We need to maintain links between Business Object and
*              the attachment.Attachment document is basiclally a
*              business object of type 'MESSAGE'.In order to maintain
*              links, first the attachment will be crated as Business
*              Object of type 'MESSAGE' using Message.Create method.
*              Need to check if we can also use FM
*              'SO_DOC_INSERT_WITH_ORIG_API1' or SO_OBJECT_INSERT rather
*              than using Message.Create method.
* I took this program and removed all the parts for adding URL's and
* notes.
* Include for BO macros
INCLUDE : <cntn01>.
* Load class.
CLASS cl_binary_relation DEFINITION LOAD.
CLASS cl_obl_object      DEFINITION LOAD.
PARAMETERS:
*  Object_a
   p_botype LIKE obl_s_pbor-typeid DEFAULT 'BUS2032',    "SO
   p_bo_id  LIKE obl_s_pbor-instid DEFAULT '0000757830', "example number
*  Object_b
   p_docty  LIKE obl_s_pbor-typeid DEFAULT 'MESSAGE' NO-DISPLAY,
   p_msgtyp LIKE sofm-doctp        DEFAULT 'EXT'     NO-DISPLAY,
*  Relationship
   p_reltyp  LIKE mdoblrel-reltype DEFAULT 'ATTA'.
TYPES: BEGIN OF ty_message_key,
        foltp     TYPE so_fol_tp,
        folyr     TYPE so_fol_yr,
        folno     TYPE so_fol_no,
        doctp     TYPE so_doc_tp,
        docyr     TYPE so_doc_yr,
        docno     TYPE so_doc_no,
        fortp     TYPE so_for_tp,
        foryr     TYPE so_for_yr,
        forno     TYPE so_for_no,
       END OF ty_message_key.
DATA : lv_message_key TYPE ty_message_key.
DATA : lo_message TYPE swc_object.
DATA : lt_doc_content TYPE STANDARD TABLE OF soli-line,
       ls_doc_content TYPE soli-line.
* Create an initial instance of BO 'MESSAGE' - to call the
* instance-independent method 'Create'.
swc_create_object lo_message 'MESSAGE' lv_message_key.
* Upload the pdf file, for now from the frontend, in the future from
* the server.
DATA:
*  dsn(40) TYPE C VALUE '/usr/sap/trans/convert/1.pdf', "server location
l_lines TYPE i. "filelenght
CALL FUNCTION 'GUI_UPLOAD'
  EXPORTING
    filename   = 'c:tsimple.pdf'
    filetype   = 'BIN'
  IMPORTING
    filelength = l_lines
  TABLES
    data_tab   = lt_doc_content.
* no exceptions, the file is there in this example
clear l_lines.
loop at lt_doc_content into ls_doc_content.
l_lines = l_lines + 255.
endloop.
compute l_lines =   l_lines
                  + STRLEN( ls_doc_content ).
** the coding for the server input, for later
*OPEN DATASET dsn FOR INPUT IN BINARY MODE.
*IF sy-subrc <> 0.
*  EXIT.
*ENDIF.
*READ DATASET dsn INTO ls_doc_content.
*WHILE sy-subrc EQ 0.
*  APPEND ls_doc_content TO lt_doc_content.
*  READ DATASET dsn INTO ls_doc_content.
*ENDWHILE.
*CLEAR ls_doc_content.
*CLOSE DATASET dsn.
* define container to pass the parameter values to the method call
* in next step.
swc_container lt_message_container.
* Populate container with parameters for method
swc_set_element lt_message_container 'DOCUMENTTITLE' 'Some title'.
swc_set_element lt_message_container 'DOCUMENTLANGU' 'E'.
swc_set_element lt_message_container 'NO_DIALOG'     'X'.
swc_set_element lt_message_container 'DOCUMENTNAME' p_docty.
swc_set_element lt_message_container 'DOCUMENTTYPE' 'PDF'.
swc_set_element lt_message_container 'DocumentSize'    l_lines.
swc_set_element lt_message_container 'DocumentContent' lt_doc_content.
swc_call_method lo_message 'CREATE' lt_message_container.
* Refresh to get the reference of create 'MESSAGE' object for attachment
swc_refresh_object lo_message.
* Get Key of new object
swc_get_object_key lo_message lv_message_key.
* Now we have attachment as a business object instance. We can now
* attach it to our main business object instance.
* Create main BO object_a
DATA: lo_is_object_a TYPE sibflporb.
lo_is_object_a-instid = p_bo_id.
lo_is_object_a-typeid = p_botype.
lo_is_object_a-catid  = 'BO'.
* Create attachment BO object_b
DATA: lo_is_object_b TYPE sibflporb.
lo_is_object_b-instid = lv_message_key.
lo_is_object_b-typeid = p_docty.
lo_is_object_b-catid  = 'BO'.
*TRY.
CALL METHOD cl_binary_relation=>create_link
  EXPORTING
    is_object_a = lo_is_object_a
    is_object_b = lo_is_object_b
    ip_reltype  = p_reltyp.
* Check if everything OK...who cares!!
COMMIT WORK.

I woudl suggest you check ORDERS05 IDOC type (ORDCHG message type).
FM - idoc_input_ordchg

Similar Messages

  • Any standard process to update Sales Order in SAP via XI / Idoc ?

    Hello,
    Currently one of our end customer is creating Sales Order in Oracle system. Once the Order is created there, they send the Order information to our XI system via flat file. XI system processes the flat file and then it calls order creation function using rfc / BAPI - BAPI_SALESORDER_CREATEFROMDAT2. This works just fine.
    But now the customer wants an ability to update sales order, cancel certain line or even cancel the whole order in their Orcale system. And once that happens, they want the same thing to happen in SAP via some kind of interface automatically in the background.
    So my question is :
    what is the best way to do it ?
    Is it possible to do via idoc ? The reason I am asking it via idoc is because it sounds that's the most standard way of doing it in SAP.
    What idocs can I use ?
    Has any one implemented such interface ? And if so, can you share some info ?
    Any response is highly appreciate.
    thanks,
    Dipankar

    I woudl suggest you check ORDERS05 IDOC type (ORDCHG message type).
    FM - idoc_input_ordchg

  • Scenario to read from txt-file and create a sales order

    Hi,
    i have started creating a scenario to read from an txt-file and to create a sales order.
    When i activate my scenario, i get the following message :
        no scenario step (vBIU) associated for this step for the incoming system (SysId)
    When i look into the detailed xml-file i see that all the records are read from the file, but there is no next step to be treated.
    Has somebody any idea how this come ?
    -<Msg MessageLog="true" msglogexcl="false" logmsg="0009" recording="true" BeginTimeStamp="20111202095144" MessageId="11120209514499820828C0A801674F24" xmlns="urn:com.sap.b1i.vplatform:entity">-<Header><msglog b1ifactive="true" always="false" step="Default message log"/>-<Resumption><starter ipo="/vP.0010000138.in_FEAN/com.sap.b1i.vplatform.runtime/INB_FI_EXST_ASYN_NAM/INB_FI_EXST_ASYN_NAM.ipo/proc"/></Resumption><IPO tid="11120205535899820808C0A801678C54" Id="INB_FI_EXST_ASYN_NAM"/><Sender Id="0010000138"/><Inbound file="ORDERS_TEST" ext="csv" path="C:\TEMP\In" pltype="txt" wrap="" deli=";"/></Header>-<Body><Payload Type="File exist" Role="T"/>-<Payload Role="S">-<io xmlns="urn:com.sap.b1i.bizprocessor:bizatoms" pltype="txt">
    -<row>
    <col>OH</col>
    <col>0000087077</col>
    <col>201110041205</col>
    <col>220</col>
    <col>9</col>
    <col>201110191702</col>
    <col>8710624300012</col>
    <col>8714252008609</col>
    <col>8710624300012</col>
    <col>8714252008609</col>
    <col>8710624300012</col>
    <col>N</col>
    <col>N</col>
    <col>N</col>
    </row>
    -<row>
    <col>OL</col>
    <col>1</col>
    <col>8711715844378</col>
    <col>20</col>
    </row>-<row>
    <col>OL</col>
    <col>2</col>
    <col>8711715844392</col>
    <col>60</col>
    </rowrow>
    <col>OL</col>
    <col>16</col>
    <col>8710251791092</col>
    <col>280</col>
    </row>
    </io>
    </Payload>
    </Body>
    </Msg>
    This is my final atom :
    <?xml version="1.0" encoding="UTF-8"?><xsl:stylesheet xmlns:b1e="urn:com.sap.b1i.sim:b1event" xmlns:b1ie="urn:com.sap.b1i.sim:b1ievent" xmlns:bfa="urn:com.sap.b1i.bizprocessor:bizatoms" xmlns:jdbc="urn:com.sap.b1i.adapter:jdbcadapter" xmlns:rfc="urn:sap-com:document:sap:rfc:functions" xmlns:sim="urn:com.sap.b1i.sim:entity" xmlns:utils2="com.sap.b1i.bpc_tools.Utilities" xmlns:vpf="urn:com.sap.b1i.vplatform:entity" xmlns:xci="urn:com.sap.b1i.xcellerator:intdoc" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" bfa:force="" vpf:force="" jdbc:force="" rfc:force="" b1ie:force="" b1e:force="" xci:force="" sim:force="" utils2:force=""><xsl:output method="xml" encoding="UTF-8" indent="yes"></xsl:output><xsl:param name="atom"></xsl:param><xsl:param name="sessionid"></xsl:param><xsl:variable name="msg" select="/vpf:Msg/vpf:Body/vpf:Payload[./@Role=&apos;S&apos;]"></xsl:variable><xsl:variable name="vpSender" select="/vpf:Msg/vpf:Header/vpf:Sender/@Id"></xsl:variable><xsl:variable name="vpObject" select="/vpf:Msg/vpf:Header/vpf:Sender/@ObjId"></xsl:variable><xsl:variable name="vpReceiver" select="/vpf:Msg/vpf:Header/vpf:ReceiverList/vpf:Receiver[./@handover=&apos;P&apos;]/@Id"></xsl:variable><xsl:template match="/">
    <Msg xmlns="urn:com.sap.b1i.vplatform:entity">
    <xsl:copy-of select="/vpf:Msg/@*"></xsl:copy-of>
    <xsl:copy-of select="/vpf:Msg/vpf:Header"></xsl:copy-of>
    <Body>
    <xsl:copy-of select="/vpf:Msg/vpf:Body/*"></xsl:copy-of>
    <Payload Role="R" id="{$atom}">
    <xsl:call-template name="transform"></xsl:call-template>
    </Payload>
    </Body>
    </Msg>
    </xsl:template><xsl:template name="transform">
    <FinalAtomResult xmlns="">
    <BOM>
    <BO>
    <AdmInfo>
    <Object>17</Object>
    <Version>2</Version>
    </AdmInfo>
         <Documents>
         <row>
         <DocDate>
              <xsl:copy-of select="$msg/io/row[0]/col[2]/text()"></xsl:copy-of>
         </DocDate>
         <DocDueDate>
              <xsl:copy-of select="$msg/io/row[0]/col[5]/text()"></xsl:copy-of>
         </DocDueDate>
         <CardCode>KD10251</CardCode>
         <NumAtCard>
              <xsl:copy-of select="$msg/io/row[0]/col[1]/text()"></xsl:copy-of>
         </NumAtCard>
         <U_PMX_JD_COMP>32</U_PMX_JD_COMP>
         </row>
                          </Documents>
         <Document_Lines>
         <xsl:for-each select="$msg/io/row">
         <row>
         <BarCode>
              <xsl:copy-of select="$msg/io/row[*]/col[2]/text()"></xsl:copy-of>
         </BarCode>
         <Quantity>
              <xsl:copy-of select="$msg/io/row[*]/col[3]/text()"></xsl:copy-of>
         </Quantity>
         </row>
         </xsl:for-each>
         </Document_Lines>

    Mike,
    you were right, you may not specify the extension of a file.
    Another thing i detected is that the loop of my data start with the index 1 instead of 0 !!!
    In this scenario, i have to read all the lines of the file and each time i should do a SQL-query,
    so that i can use the result to build my sales document.
    Do you know if it this is possible or have you any idea how to do this ?
    thx,
    Mario

  • Creating a sales order in sap via bapi

    Hi all,
    I need to create a sales order through internet in sap.
    What do I need?
    I can write programs both with abap and C#(as well as VB) well and had the knowledge a little, introduction level of java.
    How can I interact with sap from C#, is there any intermediary packet programs?
    And any code sample please?
    Thanks.
    Deniz.

    Hello Denis.
    I hope RFC has been always to the rescue in such terms.
    I have come across, "Connector"
    [SAP HELP Library - Standard Reference - RFC Parameter Mapping to C#|http://help.sap.com/saphelp_nw04/helpdata/en/0c/c59f7cd9648f408fe4943fc9dab264/frameset.htm]
    Hope that's usefull.
    Good Luck & Regards.
    Harsh Dave

  • API to create a link between Sales order and Requisition

    We are upgrade 11i to R12. We have a custom drop ship process. We have a original SO and through the sales order we create a Reqisition. We send the requisition details to the factory and the factory sends us a flat file with the quantity shipped and dates. There might be multiple lines for each requisition received. We will add the details to the SO and update the Requision with the flat file details for the SO shipment. But We will have to create a link between the SO and the requisition. Is there an API to do the linking between a SO and A requisition line?

    I created a SO and a requisition
    declare
    p_rsv inv_reservation_global.mtl_reservation_rec_type;
    p_dummy_sn inv_reservation_global.serial_number_tbl_type;
    x_msg_count NUMBER;
    x_msg_data VARCHAR2(240);
    x_rsv_id NUMBER;
    x_dummy_sn inv_reservation_global.serial_number_tbl_type;
    x_status VARCHAR2(1);
    x_qty NUMBER;
    l_inventory_item_id number;
    l_source_header_id number;
    l_reservation_qty number;
    l_error_message VARCHAR2(300);
    l_order_number NUMBER;
    begin
    fnd_global.APPS_Initialize(1131,50654,660);
    p_rsv.reservation_id := NULL;
    p_rsv.requirement_date := to_date('30-JUN-2012','DD-MON-YYYY');
    p_rsv.organization_id := 88; ---ship_from_org_id
    p_rsv.inventory_item_id := 147001; --inventory_item_id
    p_rsv.demand_source_type_id := inv_reservation_global.g_source_type_oe;
    p_rsv.demand_source_name := NULL;-------'SALES ORDER';
    p_rsv.demand_source_header_id := 27005; --- sales order header id
    p_rsv.demand_source_line_id := 29010; --- sales order line id
    p_rsv.primary_uom_code := 'EA';
    p_rsv.primary_uom_id := NULL;
    p_rsv.reservation_uom_code := 'EA';
    p_rsv.reservation_uom_id := NULL;
    p_rsv.reservation_quantity := 200;
    p_rsv.primary_reservation_quantity := 200;
    ----p_rsv.supply_source_type_id := inv_reservation_global.g_source_type_internal_req;
    p_rsv.supply_source_type_id :=inv_reservation_global.g_source_type_inv;
    p_rsv.supply_source_header_id :=18001; -- requisition header id
    p_rsv.supply_source_line_id :=12172; -- requisition line id
    p_rsv.supply_source_name := NULL;
    p_rsv.supply_source_line_detail := NULL;
    p_rsv.autodetail_group_id := NULL;
    p_rsv.external_source_code := NULL;
    p_rsv.external_source_line_id := NULL;
    p_rsv.supply_source_line_detail := NULL;
    p_rsv.revision := NULL;
    p_rsv.subinventory_code := NULL;
    p_rsv.subinventory_id := NULL;
    p_rsv.locator_id := NULL;
    p_rsv.lot_number := NULL;
    p_rsv.lot_number_id := NULL;
    p_rsv.pick_slip_number := NULL;
    p_rsv.lpn_id := NULL;
    p_rsv.attribute_category := NULL;
    p_rsv.ship_ready_flag := NULL;
    p_rsv.demand_source_delivery := NULL;
    p_rsv.attribute1 := NULL;
    p_rsv.attribute2 := NULL;
    p_rsv.attribute3 := NULL;
    p_rsv.attribute4 := NULL;
    p_rsv.attribute5 := NULL;
    p_rsv.attribute6 := NULL;
    p_rsv.attribute7 := NULL;
    p_rsv.attribute8 := NULL;
    p_rsv.attribute9 := NULL;
    p_rsv.attribute10 := NULL;
    p_rsv.attribute11 := NULL;
    p_rsv.attribute12 := NULL;
    p_rsv.attribute13 := NULL;
    p_rsv.attribute14 := NULL;
    p_rsv.attribute15 := NULL;
    inv_reservation_pub.create_reservation
    p_api_version_number => 1.0
    , x_return_status => x_status
    , x_msg_count => x_msg_count
    , x_msg_data => x_msg_data
    , p_rsv_rec => p_rsv
    , p_serial_number => p_dummy_sn
    , x_serial_number => x_dummy_sn
    , x_quantity_reserved => x_qty
    , x_reservation_id => x_rsv_id
    IF x_status='S' THEN --- HARD RESERVATION IS DONE SUCCESFULLY ---
    dbms_output.put_line('reservation succesful');
    dbms_output.put_line('reservation id: || x_rsv_id');
    ELSE
    if(nvl(x_msg_count,0) = 0) then
    dbms_output.put_line('no message return');
    else
    for I in 1..x_msg_count LOOP
    l_error_message := fnd_msg_pub.get(I, 'F');
    end LOOP;
    end if;
    --- HARD RESERVATION API fails ---
    dbms_output.put_line('Reservation API Error Message: '||l_error_message);
    END IF;
    EXCEPTION
    WHEN OTHERS THEN ------------------ In case of any pl/sql error
    l_error_message := SQLERRM;
    dbms_output.put_line('Plsql Error Message: '||l_error_message);
    END;
    but i am getting an error
    "Reservation API Error Message: INV_RSV_DS_SO"
    I am stuck and no idea how to fix this. Any help is appreciated.
    Edited by: 901524 on May 23, 2012 1:26 PM

  • Linking Between Sales Order And Purchase ORder

    Dear Gurus,
      How to link the Sales Order Number and Purchase Order Number. I know the Sales Order Number and I need the tables from which I can know the Purchase Order Numbers for that Sales Order Number.
    Points will be awarded.
    Thanks,
    Ravi

    Hi,
    Goto Table Mseg-kdauf is sales order no.
    get mseg-ebeln is purchase order.
    Or u can do the following code.
    from sales order no VBELN get VBFA-VBELV.
    SELECT SINGLE vbeln  FROM  likp
             INTO l_delno
             WHERE  vbeln   = vbfa-vbelv.
    SELECT SINGLE ebeln
               INTO l_sono
               FROM ekbe
               WHERE  belnr = l_delno    
               AND   bewtp = 'L' .  
    L_DELNO IS PURCHASE ORDER.
    If it is helpfull pls reward it.
    Regards
    Srimanta

  • Linking between Sales order data and Biling condition

    Hi Bwers,
    Currently we are geneating a report with Sales order Item level (2lis_11_VAITM) information and Biling conditions(2lis_13_VDKON). We have respective DSO for both datasources (Sales order DSO and Biling Condition DSO). We have to pull both information into a report.
    We have sales order number (0DOC_NUM) in Sales DSO and Biling document number (0BILL_NUMber) in Biling DSO. And we found Sales order Number (0BILL_NUM_0DOC_NUMB) as an navigational attribute for Biling DSO.
    We are trying to extract Billing condition type and Billing condition value from Billing DSO.
    Now the question's are:
    1. Can I use Sales order number as linking field for Both DSO' or not. Though It is an Navigational attribute for Biling document number in Biling DSO.
    2. Is the Sales order number and Billing Document number both are same or not. What is the linking field between sales order info to Biling info.
    2. How to bring Sales order info and Biling info into a report through Infoset. If infoset which link should I use bring both info into a report.
    3. Or Multiprovider is the right one.
    3. Please let me know if any other linking fields are existed between these two datasources other than Sales order.
    All the helpful answers are awareded with full points.
    Regards,
    Venkat

    1. Can I use Sales order number as linking field for Both DSO' or not. Though It is an Navigational attribute for Biling document number in Biling DSO.
    - yes you can link, Navigation attrbute does not matter
    2. Is the Sales order number and Billing Document number both are same or not. What is the linking field between sales order info to Biling info.
    --one sales order number may correspond to different billing number including the one which shares the same number.
    2. How to bring Sales order info and Biling info into a report through Infoset. If infoset which link should I use bring both info into a report.
    -- Multiprovider is the best option while dealing with such cases.
    3. Or Multiprovider is the right one.
    --yes.
    3. Please let me know if any other linking fields are existed between these two datasources other than Sales order.
    there may be possibilty of other fields also like Profit center, Controling area etc depending upon your project requirment

  • Regarding creating a LOOSE LINK between Sales Order and Vehicle

    Hi,
    Does anyone has any idea on how to establish a LOOSE LINK between Sales Order and Vehicle using BAPI_VEHICLE_CREATE or any other Function module.
    Any help will be highly appreciated and rewarded.
    Kind Regards,
    Tanuja

    Dear Kumar,
    Strategy - 40
    Consumption of PIR (not Redution)
    1) the first point in strategy in 40 is, incoming sales order consumes PIR
    2 )both sales order and PIR takes place in MRP planning run
    2) this is where it is in mostly used in many indutries
    just a small example how this strategy works
    1) creat PIR for ur FERT- 100Nos
    2) check in MD04- u will get PIR (VSF) as 100
    3) now creat sales order for 120 for same month
    4 )run MRP for that particular FERT
    5) check the result in MD04, here ur PIR gets vanishied and an plan order will be generated for 120 Nos.
    Regards
    kumar
    Edited by: kumar kumar on Jul 22, 2009 8:29 AM

  • Link between Sales order and Credit master sheet

    Hi,
    Plz explain the link between sales order and credit master sheet.
    Thanks and regards
    CSR

    Hi,
    Credit master is related to Customer.
    Credit limit will be assigned to a customer by using the T.Code FD32.
    Credit control area will be assigned to a customer.
    You can the credit control area for a customer in the table "KNVV".
    Goto the T.Code "FD32".Enter your customer number and credit control area.Select the status tab.
    Here you can maintain the credit limit.If you leave blank means the limit is 0.00.
    Next thing is goto the T.Code "OVAK".
    Select your sales order.Maintain the "Credit limit check" for your order type.
    Goto the T.Code "OVA8".Select your valid combination.Here,you can activate either the static or dynamic credit limit checks.
    If you create the sales order by using the customer,initially the system will check for the credit limit.If it is 0.00 and credit check functionality is activatd in the above specified T.Codes,then creditcheck will happen and order will be blocked for releasing of credit by using the T.Code "VKM3".Authorised persons have to release this credit block.Suppose,you have maintained this credit limit as "1000Rs/-" and you are creating the order of value "550Rs/-",then your order will not be blocked even though the credit check functionality is activated for your order type.
    In this way,sales order is in turn related to credit master.
    Regards,
    Krishna.

  • Link Between Sales Order Type and Customer/Material Exclusion

    Hi,
    Any one know the  Link Between Sales Order Type  and Customer/Material exclusion tables (Transaction: VB03 ) ?

    Hello,
    For Tcode VB03 you can check KOTG001 for Customer/Material.
    Thanks &Regards,
    Abhijit

  • Linking of sales order and production order.

    HI all,
    Currently in the system, production orders are being created without reference to sales order.
    Can someone tell me how to link a sales order to a production order? I want to know which production order is linked to which sales order. Also do let me know of the transaction to view this.

    Hi
    Use MTO strategy 20 for the header saleable part,
    then executre MRP for the Sales order using MD50.
    Now you can check the planned order assignment tab for the reference to the sales order.
    So while conversion automatically SO will be assinged to the PO
    BR
    SK

  • Uploading open sales orders from sap

    hi all,
    i need to upload open sales orders from legacy to sap. pls advice what steps need to be followed for the same.
    1) how we will we download open sales order from legacy and where..... is it to some flat file or some other option is  there . pls tell some options.
    2) how we will uload the sales ordes into sap . thru lsmw or is there some other option ?
    3)  there will be more number of fields in sap than in legacy. i think we need to manully create an excel file and add more fields manually in excel file so that the compulsonry feilds as per sap are present in sap ?
    4) how will availability check happen  in sap after sales order are t/f from legacy ?
    rgds
    pamela

    hi pamela,
    1.a. you need to down load in EXCEL in legact format and convert the same in LSMW format and upload it
    2.a. LSMW - Functionally, BDC, BAPI - Technically. to my knowledge LSMW is better option.
    3.a. first you download to EXCEL file from LEGACY, then align the same to SAP format you can add those fields that are mandatory as per your requriment.
    4.a.You are uploading sales orders in SAP which are showing OPEN status from LEGACY before you uploading the sales orders MM consultant would have uploaded its stock through 561 - dont worry on that, even though if stock is not uploaded also not an issue it will confirm at the later date.
    5.a. we have used LSMW process for our PREVIOUS ASSIGNMENT, before that we tested BAPI for it some how it was not capturing some fields.
    hope all your queries are solved
    balajia

  • Purchase Requisition & Planned Order link to sales order

    Dear Gurus,
    please help me to find the link between
    - sales order item
    and
    - ( purchase requisition & Planned orders for semi-finished )
    that created from running the MRP.
    dispite we can see all these data in one screen
    in TCode (MD4C) or (MD09)
    thnak you .
    Edited by: Alvaro Tejada Galindo on Feb 5, 2008 10:50 AM

    Hi,
    For third party order, either you can create the material master with item category group as BANS, so the system will automatically pick TAS in the sales order for the material or you can change the item category manually to TAS in the order.
    This will trigger a PR, based on the PR a PO will be generated.
    Defining Item Category Group
    IMG ® Sales and Distribution ® Sales ® Sales Documents ® Sales Document Item ® Define Item category groups
    Defining Item CategorySales and Distribution ® Sales ® Sales Documents ® Sales Document Item ® Define Item Categories
    Item category TAS
    Description 3rd party with SN CM
    Item type Blank
    Completion rule Blank
    Special stock Blank
    Relevant for billing B
    Billing plan type Blank
    Billing block Blank
    Pricing X
    Statistical value Blank
    Revenue recognition Blank
    Delimit. start date Blank
    Business data item X
    Sched. line allowed X
    Item relev. for delivery Blank
    Returns Blank
    Weight/Vol.- relevant X
    Credit active X
    Determine cost X
    Aut. batch determ. Blank
    Rounding permitted Blank
    Order qty = 1 Blank
    Incomplete proced. 28
    PartnerDetermProced T
    TextDetermProcedure 01
    Item cat. status group 1
    Screen seq. group N
    Status profile Blank
    Create PO autom. Blank
    Config. strategy Blank
    Mat. variant action Blank
    ATP material variant Blank
    Structure scope Blank
    Application Blank
    Value contract material Blank
    Contract release ctrl Blank
    Repair procedure Blank
    Billing form Blank
    DIP profile Blank
    Assigning Item Category
    IMG  Sales and Distribution  Sales  Sales Documents  Sales Document Item  Assign Item categories
    Creating Material
    MM01
    1. On the screen Create Material (Initial Screen) enter the material number if External.
    2. Choose Select View(s). (Basic View 1&2, Sales Views, Purchasing views and accounting views).
    3. Enter the relevant data and save the material. Use material group BANS in the item material group field.
    Creating SD Pricing Conditions for material
    VK11
    Creating Vendor Master
    XK01
    Regards

  • Change file name in attachment -- Sales Order

    Hi guys,
    I have to change the file name in attachment (sales order ), a pdf sent via va02 Extras/output/header/edit to mail defined in xd02.
    I used the standard program /SMB40/RVADOR01,
    what I have now : in attachement file is like 'SAPLSTXBE /20080102/174052.pdf'
    in object mail 'SAPLSTXBE /20080102/174052' .
    What can I do for changing those values?
    need urgent help please
    thanks.

    I have tried this but that doiesn't work:
    Changing the subject for email order confirmations
    An output type ZEXT was created to send emails of order confirmations to a certain distribution list in PDF format. (See the SAP Exchange Connector Implementation Documentation for details on this setup.)
    The following code and config was implemented in order to change the email subject line.
    Configuration for ZEXT (External order confirmation by email)
    Transaction: V/30
    General Data: Access Seq: 0009 (SalesOrg./Cust./Order type), Access to Conditions CHECKED.
    Replacement of text symbols – Program: ZEXT. Form routine: TEXT_SYMBOL_REPLACE
    Default Values: Transmission Medium: 5. Communication Strategy CS01.
    Mail and Titles: &KUNNR&:Order &VBELN&
    Processing Routines: Program: RVADOR01, Form Routine: ENTRY, Form: YPCC_ORDCONF_STD
    Condition Record
    Using VV12 you need to add a condition record as applicable. Note that the Communication record must point to your ZMAIL output device and has the following entry as Text for Cover Page: &KUNNR&(&VBELN&)
    Code for ZEXT subject definition
    REPORT zext.
    Author: Kevin Wilson
    Date: 01/07/2003
    Description: This program changes the title of the email for output
                 type ZEXT. Maintain output type ZEXT using V/30.
                 The mail title and texts tab has entry:
                 &KUNNR&:Order &VBELN&
                 The general tab has entry in Replacement of text
                 symbols: Program ZEXT. Form:TEXT_SYMBOL_REPLACE
    tables: kna1.
    FORM text_symbol_replace TABLES xtlines STRUCTURE tline
                             USING xthead STRUCTURE thead
                                   snast  STRUCTURE nast.
      data: t_vbeln(10) type c.
      DESCRIBE TABLE xtlines LINES  sy-tabix.
      CHECK sy-tabix GT 0.
      LOOP AT xtlines.
        move snast-objky to t_vbeln.
        replace '&VBELN&' with t_vbeln into xtlines-tdline.
        select single name1 into kna1-name1
          from kna1
          where kunnr = snast-parnr.
        replace '&KUNNR&' with kna1-name1 into xtlines-tdline.
        condense xtlines-tdline.
        modify xtlines.
      ENDLOOP.
    ENDFORM.

  • How to link the Sales Order to Planned Order in Make-to-Stock scenario

    Dear All,
    My scenario is Make-to-Stock. Now client wants to know exactly what are the process orders created for Sales order. Please let me know where I will get the link between Sales orders and Process orders in Make-to-Stock scenario.
    Regards
    Naveen

    You will require to work on the requirement type settings for MTS Scenario. The transaction code is OVZH. The requirement type for MTS is KSL.There are various rules for determining the requirement category.
    The requirement type can be determined based on the strategy group in the material master / You can also use the item category and MRP type to determine the requirement.
    Regards,
    Ashok Chauhan

Maybe you are looking for

  • Final Cut suddenly unable to capture from any source

    I suddenly started having an inability to capture in Final Cut. I have always used Final Cut Express and a Sony handicam and a firewire port. 2 weeks ago when I went to capture I started getting "dropped frames" error messages. As you know, uncheckin

  • Can no longer access same network.

    i first noticed that i cant no longer access a private netweork that i used to be able to access. except that sometimes i can. also, with this network and many others, i.e. panera or my home network, borwser errors tell me i am not connected ( safari

  • Reg Assembly Process

    Hi Guru, i would like to know the assembly Process with CIN details. please give the details regarding the above. Thanks BR siva

  • ERP2005 MSS reporting in a federated portal network

    Hello, We are implementing ERP2005 MSS on a federated portal network, and we’re facing a problem with the MSS reporting IView (application mss~rpt). When we execute this function on the producer portal (the portal connected to the ECC backend, with t

  • Update from OS X 10.5.8 to get on the cloud  What do I do??

    I am running OS X 10.5.8   what and how do I update so I can get on the cloud??