Use of input parameter of function module

Hi,
we implemented an enhancement of a function module with a new inputparameter.
Now we would like to do some follow-up to see if our developers are starting to use this new parameter.
Is there a way to find this out? We can do a program scan on the name of this new parameter, but this does not seem to be enough.
Thanks for the advice.
Kris

Hi Kris,
as described, you can do a where-used-list and expand the nodes.
This will not cover any dynamic calls.
If you want to know the real use of the new parameter, then you can implement a LOG-POINT in the function module, like
FUNCTION xyz.
IF NEW_PARAMETER IS SUPPLIED.
  LOG-POINT ID YOUR_LOG_POINT FIELDS sy-uname sy-uzeit sy-cprog NEW_PARAMETER.
ENDIF.
You can create, activate and evaluate LOG-POINTS with transaction SAAB. It is extremely helpful for a lot of analyzing purposes as you can switch logging on and off for users and servers on the fly. If you know what you want to know you can leave the log-points in the program code and just deactivate logging.
Regards,
Clemens

Similar Messages

  • How to log input parameters for Function Modules?

    Hi,
    I need to create a Logging system to trace input parameters for function modules.
    The log functionality could be done by developing a class method or a function module (For example 'write_log'), and calling it within each function module that I want to log. The 'write_log' code should be independent from the interface of the Function Module that I want to log.
    For example, I'd like to write a function/class method that can log both these functions modules:
    Function DummyA
       Input parameters: A1 type char10, A2 type char10.
    Function DummyB
       Input parameters: B1 type char20, B2 type char20, B3 type char20, B4 type Z_MYSTRUCTURE
    Now the questions...
    - Is there a "standard SAP" function that provide this functionality?
    - If not, is there a system variable in which I can access runtime all parameters name, type and value for a particular function module?
    - If not, how can I loop at Input parameters in a way that is independent from the function module interface?
    Thank you in advance for helping!

    check this sample code. here i am capturing only parameters (import) values. you can extend this to capture tables, changin, etc.
    FUNCTION y_test_fm.
    *"*"Local Interface:
    *"  IMPORTING
    *"     REFERENCE(PARAM1) TYPE  CHAR10
    *"     REFERENCE(PARAM2) TYPE  CHAR10
    *"     REFERENCE(PARAM3) TYPE  CHAR10
      DATA: ep TYPE STANDARD TABLE OF rsexp ,
            ip TYPE STANDARD TABLE OF rsimp ,
            tp TYPE STANDARD TABLE OF rstbl ,
            el TYPE STANDARD TABLE OF rsexc ,
            vals TYPE tihttpnvp ,
            wa_vals TYPE ihttpnvp ,
            wa_ip TYPE rsimp .
      FIELD-SYMBOLS: <temp> TYPE ANY .
      CALL FUNCTION 'FUNCTION_IMPORT_INTERFACE'
        EXPORTING
          funcname                 = 'Y_TEST_FM'
    *   INACTIVE_VERSION         = ' '
    *   WITH_ENHANCEMENTS        = 'X'
    *   IGNORE_SWITCHES          = ' '
    * IMPORTING
    *   GLOBAL_FLAG              =
    *   REMOTE_CALL              =
    *   UPDATE_TASK              =
    *   EXCEPTION_CLASSES        =
        TABLES
          exception_list           = el
          export_parameter         = ep
          import_parameter         = ip
    *   CHANGING_PARAMETER       =
          tables_parameter         = tp
    *   P_DOCU                   =
    *   ENHA_EXP_PARAMETER       =
    *   ENHA_IMP_PARAMETER       =
    *   ENHA_CHA_PARAMETER       =
    *   ENHA_TBL_PARAMETER       =
    *   ENHA_DOCU                =
       EXCEPTIONS
         error_message            = 1
         function_not_found       = 2
         invalid_name             = 3
         OTHERS                   = 4
      IF sy-subrc = 0.
        LOOP AT ip INTO wa_ip .
          MOVE: wa_ip-parameter TO wa_vals-name .
          ASSIGN (wa_vals-name) TO <temp> .
          IF <temp> IS ASSIGNED .
            wa_vals-value = <temp> .
          ENDIF .
          APPEND wa_vals TO vals .
        ENDLOOP .
      ENDIF.
    ENDFUNCTION.

  • What are  the input parameters for Function Module

    Dear Experts,
    I want to generate a Sales Tax returns report,those fields are not available in my existing Datasources.
    For that i want to write a Generic Datasource with Function Module.
    audat
    bukrs
    vkorg
    vtweg
    spart
    aurat
    auart
    netwr
    mwsbp
    kschl zedp(consition type)
    kschl zvat(condition type)
    ksch   zcst(condition type)
    matkl     material group
    Here what are the Input parameters for Function Module.
    Thanks in Advance.
    Srinivasan.

    Srinivasan-
    For creating a Generic extractor based on a FM, you first of all need to know what is going to be your structure.. i.e. what all fields you need to pull from what all tables. A functional consultant may help you identify the exact DB tables.
    Once you know them, hand over the requirement and the pdf mentioned by Krishna to the ABAP guy, he would be able to take this up further.
    Also decide 1st whether you would be using a full load or delta. There is a slight difference in the way they are built.
    Let me know how it goes.
    -Bhushan.

  • Fetch data from table(ET_) which is exporting parameter of function module

    Hi,
    I m new to ABAP programming.
    I have to develop a smartform that has to be filled in with fields from few tables.
    These tables have the naming convention ET_<XXX> (i.e. exporting parameter of function module).
    I m not able to directly view its contents in se11 or use select query for it.
    I have a report program which i can execute to view these parameter names.
    Now, how do i fetch data from these parameters/tables and pass it from my driver program to smartform??
    Someone pls guide me...
    Thank You.

    Hi,
    I have done that using Field-Symbols.
    Thanks,
    Preetha

  • Add parameter in Function Module

    hi all,
    I'm trying to add a parameter to function module HRGPBS_HER_GET_SURNAME_NINO.
    However, the system is telling me to carry out modification comparison first.
    Can someone guide me on using SPAU or SE95, as I don't understand what to enter in the selection area?
    thanks

    If you go to transaction code: SPAU, you can find the item (program, function module, screen, etc) in question, open the tree to the lower levels. On the lower item, you can choose to save your changes or revert back to original.
    The developers should be able to tell what has been changed. In most cases, we wanted to keep our changes with the exception of when a change was made and later a note was released to produce the same result or if new functionality is released related to the item in question.
    Hope this helps.

  • Passing parameter in function module

    hi friends,
    I have created one function module in which i need to pass PO/SO number from standard EKKO/VBAK tables through the select option parameter S_POSONO. Inside the function module I have a select query which fetches the records from a Z-table which has a field called 'REFERENCE' which is 16-char long. Hence the length mismatches with PO/SO no which is 10-char long. the first 10-char from 'REFERENCE' is PO/SO number, next 3-char is line-item num, and the last three char is schedule item num. It is required to match only first 10-char with the parameter passed i.e, S_POSONO and display only those datas.
    The function module is as follows.....
    Function :
    CALL FUNCTION 'YFIIN_RETRIEVE_SOURCE_DATA'
    EXPORTING
       LT_RANGE_BUKRS          = S_BUKRS[]
       LT_RANGE_DOCNO          = S_POSONO[]
       LT_RANGE_DOCDATE        = S_DATUM[]
       LT_RANGE_CURRENCY       = S_FCURR[]
      TABLES
        IT_TEMEXPOSU            = LT_TEMEXPOSU
    EXCEPTIONS
       INVALID_SELECTION       = 1
       OTHERS                  = 2.
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Source code inside function module:
      SELECT * FROM ZFIGL_TEMEXPOSU INTO  TABLE IT_TEMEXPOSU
                                     WHERE   COMPANY_CODE IN LT_RANGE_BUKRS
                                     AND  currency in LT_RANGE_CURRENCY
                                     and  REFERENCE in LT_RANGE_DOCNO
                                     and  doc_date in LT_RANGE_docdate.
    IF SY-SUBRC = 0.
    SELECT COMPANY_CODE ATTRIBUTE_01 REFERENCE CREATION_DATE FOREIGN_CURR                                                               
               FROM TEMT_RAWEXPOS APPENDING CORRESPONDING FIELDS OF
                   TABLE IT_TEMEXPOSU WHERE COMPANY_CODE IN  LT_RANGE_BUKRS
                                     AND REFERENCE in LT_RANGE_DOCNO
                                     AND CREATION_DATE IN  LT_RANGE_DOCDATE
                                     AND FOREIGN_CURR IN LT_RANGE_CURRENCY.
       ENDIF.
    Import Parameter of Function Modules :
    LT_RANGE_BUKRS   - type - BUKRS
    LT_RANGE_DOCNO  - type - EBELN
    LT_RANGE_DOCDATE - type - DOKDATS
    LT_RANGE_CURRENCY - type - WAERS
    please help me to solve this problem..

    Hi Ram Tej,
    Try this.
    First Read all the records without Checking REFERENCE field with LT_RANGE_DOCNO into an internal Tbale.
    Then looping at that internal table delete records from the same internal table where REFERENCE(10) <> LT_RANGE_DOCNO.
    Hope this may help ur requirement.
    Award points if useful.

  • Cursor like input parameter in function

    Hi, All !
    I have a question. I want use cursor like input parameter in function. How can I do this? Please give my an example.

    in fact i have a loop over a cursor :
    LOOP
    tmp_var:=0;
    FETCH contrat_cursor INTO contrat_rec;
              EXIT WHEN contrat_cursor%NOTFOUND;
    treatment1 -- i want to put all this trt1 in a function , and the function , since it depend on contrat_rec, will have a parameter
    end loop;
    in other context i need this function to make some trt in one row of the table contrat
    so i can get this row with select * from contrat where ...
    my question, is this ok when i give contrat_cursor%ROWTYPE as parameter to the function
    and in the second context, when i get back i row from table contrat , how can i give this row as paramer , in contrat_cursor%ROWTYPE form
    i wish it was clear
    Regards
    Elyes

  • Can i  use Two DSO 's in Function module

    hi experts,
    Can i  use Two DSO 's in Function module  .That FM is used for Layout
    I actually  want to  fill one DSO Refering the Data in Another DSO.
    Regard
    Naresh.

    In the first way the DSO's are usually called shared libraries or DSO libraries and named libfoo.so or libfoo.so.1.2. They reside in a system directory (usually /usr/lib) and the link to the executable program is established at build-time by specifying -lfoo to the linker command. In the second way the DSO's are usually called shared objects or DSO files and can be named with an arbitrary extension

  • Why we should use Macros if we have function Module

    Why we should use Macros if we have function Module and what is the Advantage of Macros than function Module
    Moderator Message: Interview-type questions are not allowed.
    Edited by: kishan P on Oct 7, 2010 2:22 PM

    Put it this way... if you have blueprints for a car you wouldn't want to produce only one car, would you? You would want to produce as many as needed. In another example, you don't want to be able to use only 1 window in Windows. Each window has common features but have different values. That's the purpose of non-static entities
    However, there are instances that you want to have only one value for something. That's when you use static entities.
    Get it? =)

  • Pls explain me the use and purpose of following Function modules

    pls explain me the use and purpose of following Function modules
    1. G_MAX_PERIOD_AND_OFFSET_GET
    2.  DEQUEUE_E_TABLE
    3. FI_COMPANY_CODE_CHECK
    4. G_PERIOD_GET
    5. alv_display_function
    6. G_SET_GET_ID_FROM_NAME
    thanks ,
    phyrose

    1. <b>G_MAX_PERIOD_AND_OFFSET_GET</b>
    For given No. of period & periods it gives the offset
    <b>2. DEQUEUE_E_TABLE</b>
    To Unlock the table records
    <b>3. FI_COMPANY_CODE_CHECK</b>
    To validate Company Code
    <b>
    4. G_PERIOD_GET</b>
    Returns no. of Posting period & Special period for give company code, posting date & ledger
    <b>5. alv_display_function</b> -
    No such FM exists
    <b>
    6. G_SET_GET_ID_FROM_NAME -</b> Use this module to derive the internal set Id from the name that appears on the user interface, for example, in order then to import the set (see the function group documentation).
    The function module first determines a candidate list of sets based on the set name and the class that might have been specified that could match the set name. The class can also be masked (e.g. 000+ for all FI-SL sets, including dynamic sets).

  • Checkbox as import parameter in function module

    Hi all,
    how to create a checkbox as import parameter in function module,
    thnx in advance

    ?? Function modules don't have screens...they do have import, export parameters.
    If you look at how "checkboxes" are stored in db tables, you'll see that the previous replies are precisely correct.  A check box is a char1 field...it is on when 'X' (ABAP_TRUE) and off when blank (initial)....you would call your FM with an import field of type char1 set to 'X' or set to space, and handle accordingly in your FM code.
    If you have a checkbox on a selection screen, then the value of that parameter is either 'X' or space, depending upon whether or not the user checked the box.

  • How to use select-options in the function module of import parameter ?

    Hi ...
       I have created a BAPI and tested in SWO1 tcode , by giving the single value for an company code ( BUKRS ) , it executed properly .
    Same thing is working after implementing in a program .
    so now it is working for fetching a single company code details .
    My requirement is : I want to use select-options in program as well as in function module IN IMPORT PARAMETER.
    Program :
    REPORT  ZTEST.
    TABLES : T001 , ZBAPI_STR .
    TYPES : BEGIN OF TY_ITEM  .
              INCLUDE STRUCTURE ZBAPI_STR .
    TYPES : END OF TY_ITEM .
    DATA :WA_ITEM TYPE TY_ITEM ,
          ITEM LIKE STANDARD TABLE OF WA_ITEM INITIAL SIZE 0 .
    PARAMETER : BUKRS TYPE ZBAPI_STR-BUKRS.
    call function 'ZBAPI_FMT001'
      exporting
        bukrs         =  BUKRS
    IMPORTING
      RETURN        =
      tables
        itemtab       = ITEM
    IF ITEM IS NOT INITIAL .
      LOOP AT ITEM INTO WA_ITEM .
        WRITE : / WA_ITEM-BUKRS , WA_ITEM-BUTXT , WA_ITEM-ORT01 , WA_ITEM-LAND1 .
      ENDLOOP.
    ENDIF.
    FUNCTION MODULE :
    FUNCTION ZBAPI_FMT001.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(BUKRS) TYPE  EFG_TAB_RANGES
    *"  EXPORTING
    *"     VALUE(RETURN) TYPE  BAPIRET2
    *"  TABLES
    *"      ITEMTAB STRUCTURE  ZBAPI_STR
    SELECT BUKRS BUTXT ORT01 LAND1 FROM T001 INTO TABLE ITEMTAB WHERE BUKRS = BUKRS .
    ENDFUNCTION.
    Regards
    Deepa.

    I have given a similiar example which i did
    Declare a
    Table type:Z_TT_PONUM             
    Short text  :  Select options  PO Number
    in SE11 tcode with row type eg: Z_ST_PONUM
    create a structure (this will be the row type)
    Structure          Z_ST_PONUM            
    Short text         Select Options Field PO number
    Compenent  Compent type
    SIGN       BAPISIGN      Inclusion/exclusion criterion SIGN for range tables
    OPTION       BAPIOPTION      Selection operator OPTION for range tables
    LOW       EBELN                      Purchasing Document Number
    HIGH       EBELN                      Purchasing Document Number
    In the function module import
    give as
    I_PO_NUM     TYPE     Z_TT_PONUM     opt  pass value Select options  PO Number
    Hope this is exactly what you want to know.
    So you create a structure simliar to mine but the low an high whould be your component
    then a table type  and then include that in the BAPI.
    Then pass your select-option value to this BAPI when you call this BAPI in the program

  • Usage problem: BI Query results as input for CRM Function module

    Hi all,
    In my VC model I have maintained a dataservice (BI query) which delivers a customer key to me. I would like to use this specific customer key output as an input parameter in a function module from my CRM system.
    I have implemented both data services and mapped the fields. However, the problem is as follows:
    The query gives an output customer number: 001044082163. The customer_id in CRM is 44082163, so the output from BW needs to be changed to 0044082163 (as we need to input 10 characters).
    So the question is: How can we change the output from BI query 001044082163 to 0044082163 within the VC model?
    Best regards,
    Jan Laros

    Hi
    try this expression
    '00'&MID(@BI_CUST_NO,4,8)
    Good luck
    Ola

  • Populating the output parameter in function module.

    Hi Experts,
       I have written a function module,with material number,BEZEI as input and mvgr2 as output from table tvm2t.I am facing a problem in populating the material number as well in outputtable.The material number in input is nothing to do with output.
    please help me at the earliest.
    Regards,
    Sridevi.

    Hmmm, you wrote that the output is 'table parameter' but you mention 2 single fields. If you expect a good reply here, it helps to mention how you defined the table and how you select the data for the output. For example: input is matnr and you select the material group of this matnr. Output is all other matnr of this material group. Then we would know what you want to do here.
    So please describe what you need and give us the table description.
    Regards
    Nicola

  • (internal) Tables obsolete as parameter in function modules,

    Hi
    As you probably can see by the question, my ABAP Knowledge isn't exactly overwhelming !
    <i>anyway:</i>
    I'm trying to create a function module in NW2004s, This functionmodule should take an internal table, based on a structure as (import) parameter.
    In the earlier version, I've done this by defining it under the TAB 'Tables' in the function builder - But know its telling me that "<i>Tables Parameters are obsolete</i>", and that I should define it under "Changing" instead.
    I have tried that, but I'm only allowed to pass a single line, and if I try to do a Loop, in the function module, it tells me that ity isn't created as an internal table.
    So please - what is the "best practice" here ?
    Regards
    Morten Nielsen

    Hi All,
    I followed Steps 1 and 2 but when I use the following select statement I get a dump with the error enclosed.
    Step1. Created a structure ZDFKKCOHI which is a replica of DFKKCOHI.
    Step2. Created a table type ZDFKKCOHITABLE with line type as ZDFKKCOHI.
    Step3. In my function module I have a changing parameter ZDFKKCOHIPARAM of type ZDFKKCOHITABLE.
    Step 4. When I use the following select clause I am getting a dump.
    DATA: wa_zdfkkcohi LIKE LINE OF zdfkkcohiparam.
      SELECT *
      FROM dfkkcohi
      INTO  CORRESPONDING FIELDS OF TABLE zdfkkcohiparam
      WHERE cotyp EQ zcotyp
      AND gpart EQ zgpart
      AND corr_status EQ zcorr_status.
      LOOP AT zdfkkcohiparam INTO wa_zdfkkcohi.
    *Move IT_ZDFKKCOHI to ZDFKKCOHIOUT.
    *Append ZDFKKCOHIOUT.
    *Clear IT_ZDFKKCOHI.
      ENDLOOP.
    What could be wrong?
    Thanks for all your help in advance.
    Regards,
    Divya

Maybe you are looking for

  • Iphone 4 speaker won't work after ios 4.3.2 upgrade

    I upgraded to 4.3.2 yesterday and since then the speaker on my iphone 4 has stopped working completely. Phone will not ring, ipod won't play, no sound on the speaker at all. Can use the phone but no speakerphone or any other sound on the speaker. Ple

  • An error occurred in the source system when running infopackage

    Hello, I am using 0CO_PC_PCP_03 (Product Cost Planning: Itemizations Costing) and cube 0COPC_C10 (Exploded Itemization) in BI. RSA3 extractor checker shows that there is data if you put in a period.But as soon as I run the infopackage I get error   

  • Express XY plot - Overplot timeline

    I tried to plot a graph using the XY Express. The X axis is a timeline. The problem starts to occur after 5 minutes. The X axis (timeline) doesn't move itself, but for instance, there is no problem if the timeline axis moves. The past is not too impo

  • Weblogic 8.1 & Embedded LDAP server

    Hi, Is it possible to store user attributes alongwith username & password in the Weblogic 8.1 Embedded LDAP Server?. We have about 6 user profile attributes along with the username & password. Does weblogic's embedded LDAP Server support this feature

  • Slow page rendering due to a LOV!

    I was trying to figure out what the cause of my slow page rendering was and looking at the debug results I figured for one of my page items which is a LOV I get: 0.18800     13.98400     ...Session State: Save "P2_CATEGORY" - saving same value: "4"co