Reverse function module of this FM "UNIT_OF_MEASURE_SAP_TO_ISO"

Hi,
I want the reverse Function module for this given function module UNIT_OF_MEASURE_SAP_TO_ISO

Hi Josephine Clara
check the input and the output fields, i guess you must be giving them reverse.........
ISO_CODE you have to give the input parameters in it and the output parameters will be in SAP_CODE
ISO_CODE = 'EA'.
after executing (F8) the output will be
SAP_CODE  = 'CDA'.
rest i have to check the code

Similar Messages

  • How to make this function module as RFC to get data from different system?

    Hi
    I am trying to use following function module . This function module is used to copy data from one cube to another cube within same system however I need a this should happen across two different system. How can I use this function module to make it remote call to different system and do the same function what it is doing ?
    Name of function module -
    RSDRT_INFOCUBE_DATA_COPY
    Any help would be really helpful
    AG

    HI,
      let us say you want to copy the data of a cube in system A to a cube in system B .
      1) create a RFC function module in system B (in this function module  call the function module RSDRI_CUBE_WRITE_PACKAGE to update the data), this RFC function module should have same parametersa as RSDRI_CUBE_WRITE_PACKAGE .
    2) write a program in system A .. read the data from the infocube using the function module RSDRI_INFOPROV_READ and call the RFC function module in system B that you have created..
    for the details of the parameters to pass to these two function modules use the RSDRT_INFOCUBE_DATA_COPY and get the required code
    Thanks
    mahesh

  • Function Modules - Urgent

    Hi,
    I need to create a Function Module where this FM should send a document as attachment to the internet mail id , example [email protected]
    Please help me out.
    Thanks,
    Pavan.

    Hi,
    Will a prog. be fine for sending a mail to xternal mail id??
    Mail with attachments: SO_NEW_DOCUMENT_ATT_SEND_API1
    Mail without attachments: SO_NEW_DOCUMENT_SEND_API1
    For Understanding the Function Module
    SO_OBJECT_Send:
    http://www.thespot4sap.com/articles/SAP_Mail_Understanding_SO_Object_Send.asp
    Try this:
    REPORT  zsendemail                    .
    PARAMETERS: psubject(40) type c default  'Testing',
                p_email(40)   type c default '[email protected]'.
    data:   it_packing_list like sopcklsti1 occurs 0 with header line,
            it_contents like solisti1 occurs 0 with header line,
            it_receivers like somlreci1 occurs 0 with header line,
            it_attachment like solisti1 occurs 0 with header line,
            gd_cnt type i,
            gd_sent_all(1) type c,
            gd_doc_data like sodocchgi1,
            gd_error type sy-subrc.
    data:   it_message type standard table of SOLISTI1 initial size 0
                    with header line.
    *START-OF-SELECTION.
    START-OF-SELECTION.
    Perform populate_message_table.
    *Send email message, although is not sent from SAP until mail send
    *program has been executed(rsconn01)
    PERFORM send_email_message.
    *Instructs mail send program for SAPCONNECT to send email(rsconn01)
    perform initiate_mail_execute_program.
    *&      Form  POPULATE_MESSAGE_TABLE
    *       Adds text to email text table
    form populate_message_table.
      Append 'Line1' to it_message.
      Append 'Line2' to it_message.
      Append 'Line3' to it_message.
      Append 'Test- 1' to it_message.
    endform.                    " POPULATE_MESSAGE_TABLE
    *&      Form  SEND_EMAIL_MESSAGE
    *       Send email message
    form send_email_message.
    * Fill the document data.
      gd_doc_data-doc_size = 1.
    * Populate the subject/generic message attributes
      gd_doc_data-obj_langu = sy-langu.
      gd_doc_data-obj_name  = 'SAPRPT'.
      gd_doc_data-obj_descr = psubject.
      gd_doc_data-sensitivty = 'F'.
    * Describe the body of the message
    * Information about structure of data tables
      clear it_packing_list.
      refresh it_packing_list.
      it_packing_list-transf_bin = space.
      it_packing_list-head_start = 1.
      it_packing_list-head_num = 0.
      it_packing_list-body_start = 1.
      describe table it_message lines it_packing_list-body_num.
      it_packing_list-doc_type = 'RAW'.
      append it_packing_list.
    * Add the recipients email address
      clear it_receivers.
      refresh it_receivers.
      it_receivers-receiver = p_email.
      it_receivers-rec_type = 'U'.
      append it_receivers.
    * Call the FM to post the message to SAPMAIL
      call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
           exporting
                document_data              = gd_doc_data
                put_in_outbox              = 'X'
           importing
                sent_to_all                = gd_sent_all
           tables
                packing_list               = it_packing_list
                contents_txt               = it_message
                receivers                  = it_receivers
           exceptions
                too_many_receivers         = 1
                document_not_sent          = 2
                document_type_not_exist    = 3
                operation_no_authorization = 4
                parameter_error            = 5
                x_error                    = 6
                enqueue_error              = 7
                others                     = 8.
    * Store function module return code
      gd_error = sy-subrc.
    * Get it_receivers return code
      loop at it_receivers.
      endloop.
    endform.                    " SEND_EMAIL_MESSAGE
    *&      Form  INITIATE_MAIL_EXECUTE_PROGRAM
    *       Instructs mail send program for SAPCONNECT to send email.
    form initiate_mail_execute_program.
      wait up to 2 seconds.
      if gd_error eq 0.
          submit rsconn01 with mode = 'INT'
                        with output = 'X'
                        and return.
      endif.
    endform.                    " INITIATE_MAIL_EXECUTE_PROGRAM
    Regards,
    Anjali

  • Function Module to open a new session displaying a method of a class

    Hello All,
    I have a method A of class B.
    Now, in my current session, I have a button. When the user clicks on this button, what I expect is that a new session be opened and in the new session method A of class B be displayed.
    This is similar to the debugger, wherein, in the debugging mode, we can bring up the context menu in the Source Code (Edit Control) tool, and then select "Go To Source Code".
    So basically, I am looking for a Function Module which does the same.
    I came across Function Module CC_CALL_TRANSACTION_NEW_TASK, however, this will only create a new session.
    I could specify the transaction as SE24, but it then opens a new session with this transaction. That is it.
    My objective is to display the method of a class in a new session.
    Is there any Function Module in this case?
    Regards,
    Mithun
    Edited by: Mithun Kamath on Aug 9, 2011 5:35 PM

    Hello Sandra,
    Thank you very much. That was exactly what I was looking for.
    However, instead of calling EDITOR_PROGRAM directly, what I instea did was the following:
    1) Created a RFC enabled Function module.
    2) Inside this function module, I wrote the following code:
      SUBMIT tpda_editor_start AND RETURN
       WITH prgm  = is_alert_det-program_name
       WITH incl = is_alert_det-include_name
       WITH dynp = space
       WITH line = is_alert_det-line_no.
    The parameters above were similar to the one proposed by you.
    Borrowed the above from the class CL_TPDA_SERVICES_TOOLS, method NAVIGATE_TO_SOURCE.
    The above is basically called in the debugger, when we use the context menu in the editor tool and invoke the "Goto Source Code" functionality. This eventually calls the EDITOR_PROGRAM FM.
    The reason why I did this is because when I was testing the FM, it did not allow me to specify the include as CL_TEST=====CM01. I do not know why, probably I was doing it wrong. But it gave me a message saying that the object does not exist in table TADIR.
    Anyway, I did the above steps and it worked exactly as I wanted it to.
    I would like to thank you again.
    Best Regards,
    Mithun
    P.S. Forgot to add, I called the above RFC enabled FM as a new task.
    Edited by: Mithun Kamath on Aug 10, 2011 4:19 PM

  • Closing Stock of a particular date:Function Module

    Hello Experts,
    I m developig a report in which I want Closing Stock amount of a particular date.
    Is there any funtion module for this, as in tables S031, mard I m getting Closing Stock as on date.
    Pls suggest
    Priyanka

    Hi Priyanka,
    I didnt find any function module for this purpose.
    You can create your FM for this purpose.
    You can refer following thread for the reference:
    Re: closing stock of a particular date
    Closing Stock of a Material
    Re: Stock on a particulare date
    Hope this will help.
    Regards,
    Nitin.

  • Error when call RFC Function module in R/3

    Dear All,
    We are trying to call RFC function module CBIF_GLM1_PROCESS_ORDER_READ (This is not a BAPI and also not released ) in R/3 from XI system.
    we are facing the error "Error while lookup Exception during processing the payload. Error when calling an adapter by using the communication channel CC_PPPI_MES_RFC_Rcvr (Party: , Service: WCD_320, Object ID: 16563889b449328eac76caa6a3bc592e) XI AF API call failed. Module exception: 'error while processing the request to rfc-client: com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: failed to parse BAPI response due to: com.sap.aii.adapter.rfc.util.bapi.BapiException: Parameter with name RETURN not found.'. Cause Exception: 'com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: error while processing message to remote system:com.sap.aii.adapter.rfc.core.client.RfcClientException: failed to parse BAPI response due to: com.sap.aii.adapter.rfc.util.bapi.BapiException: Parameter with name RETURN not found.'."
    This is the first time we are doing this configuration.
    Could you please let me know what woulbe the reason.

    read the original message
    We are trying to call RFC function module CBIF_GLM1_PROCESS_ORDER_READ (This is not a BAPI and also not released ) in R/3 from XI system.
    I am talking about the above Receiver RFC channel which you guys are using to call R/3 from XI. That where you need to change the commit parameter

  • Creating a Function Module for Standard Include

    Hi ALL,
    There is a standard Include in that i have created 1implicit Enhancement Point and there is 200 lines code is there ,so my client is saying to keep this code in function module. This is the below code  can any one do how to write this code in function module with passing parameters and all the stuff.Means Import parameters ,Export parameters and Source code ?
      Perform change_order_va02.
      data: l_vbfa like vbfa,
            l_FKART like vbrk-FKART,
            l_fksto like vbrk-fksto,
            l_sfakn like vbrk-sfakn.
      data: begin of lt_vbfa occurs 0,
              vbeln like vbfa-vbeln,
            end of lt_vbfa.
      if komfk-vbtyp ca 'PO'.              " debit/credit memo
        select vbeln into table lt_vbfa from vbfa
               where vbelv = KOMFK-VBELN and
                     ( vbtyp_n = '5' or vbtyp_n = '6' ).
          loop at lt_vbfa.
            clear: l_fksto, l_sfakn.
            select single FKART fksto SFAKN into (l_FKART, l_fksto, l_sfakn)
                   from vbrk
                   where vbeln = lt_vbfa-vbeln.
            check: sy-subrc = 0,
                   l_fksto is initial,
                   l_sfakn is initial.
                 message e310(zz) with l_FKART l_vbfa-vbeln.
          endloop.
      endif.
    *}   INSERT
    ENDFORM.
    *{   INSERT         D01K9A0PBY                                        1
    *&      Form  change_order_va02
      228810/45115 FUWAGNK implement VA02 into VF01 for Turkey
    -->  p1        text
    <--  p2        text
    FORM change_order_va02.
    Tables : *knvi, *lips, *likp.
    DATA: Z_MODE value 'N'.
    data: hf-date(10).
    DATA: BEGIN OF BDC_TAB OCCURS 0.
           INCLUDE STRUCTURE BDCDATA.
    DATA: END OF BDC_TAB.
    DATA: BEGIN OF BDC_MSG OCCURS 0.
           INCLUDE STRUCTURE BDCMSGCOLL.
    DATA: END OF BDC_MSG.
    select single vbeln vgbel from *lips into corresponding
           fields of *lips
                  where vbeln = KOMFK-VBELN.
    select single vbeln LFART from *likp into corresponding
           fields of *likp
                  where vbeln = KOMFK-VBELN.
    if *likp-lfart = 'LF'.
    select single vbeln vkorg kunnr from vbak into corresponding
           fields of vbak
                  where vbeln = *lips-vgbel.
    if vbak-vkorg = '1252'.
       clear bdc_tab. refresh bdc_tab.
       move 'SAPMV45A' to BDC_TAB-PROGRAM.
       move '102 '     to BDC_TAB-DYNPRO.
       move 'X'        to BDC_TAB-DYNBEGIN.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       move: 'VBAK-VBELN'  to BDC_TAB-FNAM,                   "Doc.Number
              VBAK-VBELN   to BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       MOVE: 'BDC_OKCODE'  TO  BDC_TAB-FNAM,                 "OK-CODE
              '/00 '        TO  BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       move 'SAPMV45A' to BDC_TAB-PROGRAM.
       move '4001'     to BDC_TAB-DYNPRO.
       move 'X'        to BDC_TAB-DYNBEGIN.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       MOVE: 'BDC_OKCODE'  TO  BDC_TAB-FNAM,                 "OK-CODE
              'KKAU '      TO  BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       move 'SAPMV45A' to BDC_TAB-PROGRAM.
       move '4002'     to BDC_TAB-DYNPRO.
       move 'X'        to BDC_TAB-DYNBEGIN.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       select single * from *KNVI into *KNVI where KUNNR = vbak-kunnr
                                               and ALAND = 'TR'
                                               and TATYP = 'MWST'
                                               and TAXKD = '2'.
       if sy-subrc =  0.
          exit.
       endif.
       move: 'VBAK-WAERK'  to BDC_TAB-FNAM,               "Currency
             'YTL '        to BDC_TAB-FVAL.
             APPEND BDC_TAB. CLEAR BDC_TAB.
       write sy-datum to hf-date.
       move: 'VBAK-AUDAT'  to BDC_TAB-FNAM,                   "Doc.Number
              hf-date      to BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       move: 'VBKD-PRSDT'  to BDC_TAB-FNAM,                   "Doc.Number
              hf-date      to BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       MOVE: 'BDC_OKCODE'  TO  BDC_TAB-FNAM,                  "OK-CODE
              '/11 '        TO  BDC_TAB-FVAL.
       APPEND BDC_TAB. CLEAR BDC_TAB.
       CALL TRANSACTION 'VA02'
            USING BDC_TAB MODE Z_MODE UPDATE 'S'
                  MESSAGES INTO BDC_MSG.
         IF SY-SUBRC NE 0.
            clear bdc_tab. refresh bdc_tab.
         endif.
      endif.
    endif.
    ENDFORM.                    " change_order_va02
    Regards,
    Venkat

    ans

  • How to make use of SE37- Function Module & how to find out the table?

    Hi ,
    1.Could anyone help me what's this SE37-Function module is all about,How to make use of this?
    For Eg,If i want to delete a BOM permanently from the system then I have to use the Function module CM_DB_DEL_FROM_ROOT_BOM.
    But after giving the particular name what should i do?
    Please help me.
    2.How to find out the respective table for a particular field sya for T code-COGI, T code MFBF,where its values are getting populated.,Please help in this issue.
    Thanks in adavnce for spending some time
    Raj.S

    Hi Raj
    Function Modules
    Function modules are procedures that are defined in special ABAP programs only, so-called function groups, but can be called from all ABAP programs. Function groups act as containers for function modules that logically belong together. You create function groups and function modules in the ABAP Workbench using the Function Builder.
    Function modules allow you to encapsulate and reuse global functions in the SAP System. They are managed in a central function library. The SAP System contains several predefined functions modules that can be called from any ABAP program. Function modules also play an important role during updating  and in interaction between different SAP systems, or between SAP systems and remote systems through remote communications.
    Unlike subroutines, you do not define function modules in the source code of your program. Instead, you use the Function Builder. The actual ABAP interface definition remains hidden from the programmer. You can define the input parameters of a function module as optional. You can also assign default values to them. Function modules also support exception handling. This allows you to catch certain errors while the function module is running. You can test function modules without having to include them in a program using the Function Builder.
    The Function Builder  also has a release process for function modules. This ensures that incompatible changes cannot be made to any function modules that have already been released. This applies particularly to the interface. Programs that use a released function module will not cease to work if the function module is changed.
    Check this link
    http://help.sap.com/saphelp_nw2004s/helpdata/en/9f/db988735c111d1829f0000e829fbfe/content.htm
    You can execute function module in SE37ie you can perform the activiites defined in the function module by executing it.
    By deleting BOM you mention the FM name in se37 and execute. In some function module it will ask input parameters as developed in the program , you have to give the input parameters and execute.

  • Function Module for creation of variant in BADI

    I need to create a variant to store shipment no's which are coming in BADI. And variant need to be passed to a report which has to be run  Background. can anyone help me out how to do it. Can anyone know the function module for this.

    Hi Anirban,
    Use the bapi BAPI_BUSPROCESSND_CREATEMULTI to achieve the same.
    <b>Reward points if it helps.</b>
    Regards,
    Amit Mishra

  • How to retrieve data from a function module and use it in sap script??

    I have a report program, which calls a function module. This function module internally calls an include program. In this program, I have a variable which is to be used in the sap script. How can I send this variable to the sap script

    Hi,
    In your case, Include prog is part of FM, no need to treat it as an Entity.
    Now, Your Answer -
    In SCRIPT - IN Page Window -->
         PERFORM GET_MVAT_TIN IN PROGRAM Z_SCRIPT_PERFORMS_ABAPDB3
         USING &VBDKR-KUNRE&
         CHANGING &STCD1&
         CHANGING &STCD2&
         ENDPERFORM
         IF &STCD1& <> ' '
         <B>MVAT Number :</> &STCD1&
         ENDIF
    Then go to SE38 --> Creat prog with type - Subroutine pool
    In that Write FORM statement for this PERFORM.
    FORM get_mvat_tin TABLES inttab STRUCTURE itcsy
                             outtab STRUCTURE itcsy.
      DATA : v_kunre TYPE kna1-kunnr,
             v_stcd1 TYPE kna1-stcd1,
             v_stcd2 TYPE kna1-stcd2.
      LOOP AT outtab.
        CLEAR outtab-value.
        MODIFY outtab.
      ENDLOOP.
      READ TABLE inttab INDEX 1.
      v_kunre = inttab-value.
      IF v_kunre CA sy-abcde.
      ELSE.
        UNPACK v_kunre TO v_kunre.
      ENDIF.
       " Here You can take your Funcion module ***************************
      SELECT SINGLE stcd1 stcd2 FROM kna1 INTO (v_stcd1, v_stcd2)
                                         WHERE kunnr = v_kunre.
      IF sy-subrc = 0.
        READ TABLE outtab INDEX 1.
        WRITE v_stcd1 TO outtab-value.
        MODIFY outtab INDEX 1.
        READ TABLE outtab INDEX 2.
        WRITE v_stcd2 TO outtab-value.
        MODIFY outtab INDEX 2.
      ENDIF.
    ENDFORM.                                

  • Jco Call a Function Module in BackGround

    Hello All.
    Some one can send me a simple exemplo how to call a ABAP Function Module in BackGround.
    Can i set this in Java side?
    ..or only set the BackGround Work Process in SAP side?
    In my java application call the Abap Function Module like this:
    client.execute(function);
    How to set parameters to execute the function in BackGround.
    My rpoblem is when the return the data to java side ...occurs the error TIME_OUT in Dialog WorkProcess.
    I need to call in background to better performance and to prevent the TIME_OUT.
    Best regards.
    Taylor.

    Hi.
    I don’t know how to do, but, you can do a previous RFC, this new RFC execute the original function in background mode. I did something like that:
    - JAVA: client.execute("RFC_FUNCTION", input, output);
    - SAP: RFC_FUNCTION:
    CALL FUNCTION func IN BACKGROUND TASK
                         [DESTINATION dest]
                         parameter_list
                         [AS SEPARATE UNIT].
    or
    CALL FUNCTION update_function IN UPDATE TASK
                                 [EXPORTING p1 = a1 p2 = a2 ...]
                                 [TABLES t1 = itab1 t2 = itab2 ...].
    I hope that help you

  • Function module to get adress in line items

    Dear All
    I am using a function module ADDR_GET which is giving me the data in a specific format of addr_val1, Now the requirement is to display the data in a script , so that the address comes as address line 1 ,line 2 and likewise.... Kindly let me know if there are any function modules in this regard <Priority normalized by moderator>
    Edited by: Vinod Kumar on Dec 30, 2011 4:33 PM

    hello!
    i think you could use the address node. It formats the address automatically according to the postal regulations of the sender country...you only need to pass the adrnr to it.
    the link below gives more info abt. the address node.
    http://help.sap.com/saphelp_nw70/helpdata/en/d2/69a151cd8b11d3b563006094192fe3/content.htm

  • Function Module for getting the Sales Price for a condition type

    Hi,
    I am looking for a standard function module to which I can pass my condition type(new customizing) and it will return the sales price. The customer is going to create some new condition type to manitain the sales price. I'll have the necessary information like material/sales org/distribution channel, customer and need the standard function module to read the condition records for that condition type(as configured) and give me the price. PLease help if you know of a standard function module performing this.
    Thanks in advance.
    Regards
    Malthi

    Hi malthi ,
    welcome to sdn
    for material sales area u can look for the validations is table MVKE.
    the classification of the conditions is in tables like A901, a902 etc which in my opinion holds the condition types per classification .
    put a A* in se11 and this will give the list of tables per classification .
    u need to get the conditions as per kschl and dmbtr and
    etc..
    like this ..
    Get Condition Values for Material/Plant combination
      IF NOT i_a916[] IS INITIAL.
        SELECT knumh kappl kschl krech
               kbetr konwa kpein kmein
               INTO TABLE i_konp
               FROM konp
               FOR ALL ENTRIES IN i_a916
               WHERE knumh EQ i_a916-knumh AND
                     kappl EQ i_a916-kappl AND
                     kschl EQ i_a916-kschl AND
                     loevm_ko NE 'X'.
      ENDIF.
    Get Condition Values for Material/Plant/Ordertype/
    Customer combination
      IF NOT i_a925[] IS INITIAL.
        SELECT knumh kappl kschl  krech
               kbetr konwa kpein kmein
               APPENDING TABLE i_konp
               FROM konp
               FOR ALL ENTRIES IN i_a925
               WHERE knumh EQ i_a925-knumh AND
                     kappl EQ i_a925-kappl AND
                     kschl EQ i_a925-kschl AND
                     loevm_ko NE 'X'.
      ENDIF.
    just check this Fm if u can apply ur condition over here ..
    ME_GET_PRICE_CONDITION
    regards,
    VIjay.

  • How to create function module for getting customer name

    Hi Experts,
                   How to create function module?  when in import parameter kunnr values to be passed it must give name1 details according to the customer number...
    how to write the logic in source code....
    Regards,
    Thiru. R

    1. First of all create function group.
    2. Create function module using this function group.
    3. If only one kunnr is needed at a time, create import parameter for it. But if many kunnr to be entered at a time,use table.
    4. Fetch name1 for each kunnr from KNA1 table.
    "->> if many kunnr
    if not t_kunnr[] is initial.
    select kunnr as kunnr name1 as name1
    into table t_kunnr_name1
    from kna1
    for all entried in table t_kunnr
    where kunnr = t_kunnr-kunnr.
    endif.       
    sort t_kunnr_name1 by kunnr name1.
    delete adjacent duplicates from t_kunnr_name1 comparing kunnr name1.
    table t_kunnr_name1 will contain kunnr and its name1.
    I hope logic is clear for you now.
    Regards,
    Aparna

  • How to create a generic data extractor using standard function module

    Hi,
    I have to generate report based on Function module(standard FM),client know only Fm Name n they have given FM Name n asked reports based on that, so can any one give me steps to create DS based on that.
    Thanks,
    Swapna

    check this blog
    /people/siegfried.szameitat/blog/2005/09/29/generic-extraction-via-function-module
    and this pdf:
    Generik extraction: https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/a0f46157-e1c4-2910-27aa-e3f4a9c8df33
    Generic delta:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/84bf4d68-0601-0010-13b5-b062adbb3e33
    Edited by: Aduri on Dec 17, 2007 4:04 PM

Maybe you are looking for