How to - customize datasource by means of 'Function module'  via 'RSO2' ?

Wilson, the topic of Function Module extractors is well documented in the forums - please search the forums before posting
+__Hi,Expert:__+
+__Could you please kindly advise me how to customize datasource by  'Function module',__+
+__and which aspects I should pay more attention?__+
+__Or provide me valuable documentation.__+
+__Thanks very much !__+
Edited by: Arun Varadarajan on Feb 11, 2009 9:58 AM

Hi Wilson,
              Check here..........
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/a0f46157-e1c4-2910-27aa-e3f4a9c8df33
https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/84bf4d68-0601-0010-13b5-b062adbb3e33
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d3219af2-0c01-0010-71ac-dbb4356cf4bf
Generic extractor based on function module RSAX_BIW_GET_DATA_SIMPLE
Thanks,
Vijay.

Similar Messages

  • How to pass BI Query parameters from Function Module

    Hi,
    We are executing the BI queries using the Function Module "RS_VC_GET_QUERY_VIEW_DATA_FLAT" by passing the query name and the provider information.
    Is there a way, to pass the filter parameter values also to the query by using this function module? I am not sure how the VC  tool is using this Function Module to call the BI queries and passing the filter values.
    Your help is appreciated.
    Thanks
    Suri

    Suryanarayana,
    Are you trying to execute a query in batch?. If you want to execute try to look at WRITEQUERY - which is a standard SAP program. You can execute this program directly or you can customize it completely and produce the output in .CSV file.
    Hope this helps. Award points if useful.
    Goodluck,
    Alex (Arthur Samson)

  • How to get sysnr value in a Function Module

    Hi all,
    I need to get the sysnr(system number) value of the R/3 system. I execute a RFC function module and need to get the value of sysnr of the system it executes in as a return parameter. Can somebody tell me how to get this value in the function module and return it.
    Thanks and Regards,
    Pratik

    Hello Pratik
    The system number has to be defined in the RFC destination. Thus, select on your local system (where you call the RFC function module) the corresponding RFC destination from table <b>RFCDES</b>. In field RFCDES-RFCOPTIONS you will find a string like this:
    H=<ip address>,S=21,R=N, ...
    S=system number
    Regards
      Uwe

  • How to pass select-option filed to Function Module Exporting Parameter

    Hi,
        How to pass select-option filed to Function Module Exporting Parameter.
    Thanks

    Hi,
    DATA: BEGIN OF ITAB5_WRK OCCURS 0,
            KUNNR     TYPE KNKK-KUNNR,  "CUSTOMER #
            SBGRP     TYPE KNKK-SBGRP,  "CREDIT REP
            KLIMK     TYPE KNKK-KLIMK,  "CREDIT LIMIT
            NAME1     TYPE KNA1-NAME1,  "CUSTOMER NAME
            SKFOR     TYPE KNKK-SKFOR,  "TOTAL A/R
            AMT1      TYPE KNKK-SKFOR,  "CURRENT
            AMT2      TYPE KNKK-SKFOR,                          "01-30
            AMT3      TYPE KNKK-SKFOR,                          "31-60
            AMT4      TYPE KNKK-SKFOR,                          "61-90
            AMT5      TYPE KNKK-SKFOR,                          "91-120
            AMT6      TYPE KNKK-SKFOR,                          "OVR 120
            BZIRK     TYPE KNVV-BZIRK,
          END OF ITAB5_WRK.
    SELECT-OPTIONS P_COMP     FOR  T001-BUKRS
      SELECT KUNNR SBGRP  FROM KNKK
             INTO TABLE ITAB5_WRK
             WHERE SBGRP IN P_REP
               AND KUNNR GE '0001000000'
               AND SKFOR NE 0.
      LOOP AT ITAB5_WRK.
        DELETE ADJACENT DUPLICATES FROM ITAB5_WRK COMPARING KUNNR.
      ENDLOOP.
      PERFORM GET_CREDIT_LIMITS.
    *=======================================================================
      IF P_DIST NE SPACE.
        LOOP AT ITAB5_WRK.
          SELECT SINGLE * FROM KNVV WHERE KUNNR EQ ITAB5_WRK-KUNNR
                                      AND VKORG EQ P_COMP
                                      AND VTWEG EQ '20'
                                      AND SPART EQ '10'
                                      AND BZIRK IN P_DIST.
          IF SY-SUBRC EQ 0.
            MOVE KNVV-BZIRK TO ITAB5_WRK-BZIRK.
            MODIFY ITAB5_WRK.
          ELSE.
            DELETE ITAB5_WRK.
          ENDIF.
        ENDLOOP.
      ENDIF.
    *==============================================================
      LOOP AT ITAB5_WRK.
        MOVE: 'F/S'            TO WRK-KKBER,
               ITAB5_WRK-KUNNR TO WRK-KUNNR.
        PERFORM AGING.
        ADD: W_SNFAE  TO ITAB5_WRK-AMT1,
             W_SFAE1  TO ITAB5_WRK-AMT2,
             W_SFAE2  TO ITAB5_WRK-AMT3,
             W_SFAE3  TO ITAB5_WRK-AMT4,
             W_SFAE4  TO ITAB5_WRK-AMT5,
             W_SFAE5  TO ITAB5_WRK-AMT6,
             W_SFAEL  TO ITAB5_WRK-SKFOR,
             W_SNFAE  TO ITAB5_WRK-SKFOR.
        MOVE: 'SPEC'            TO WRK-KKBER,
               ITAB5_WRK-KUNNR TO WRK-KUNNR.
        *PERFORM AGING.*
        ADD: W_SNFAE  TO ITAB5_WRK-AMT1,
             W_SFAE1  TO ITAB5_WRK-AMT2,
             W_SFAE2  TO ITAB5_WRK-AMT3,
             W_SFAE3  TO ITAB5_WRK-AMT4,
             W_SFAE4  TO ITAB5_WRK-AMT5,
             W_SFAE5  TO ITAB5_WRK-AMT6,
             W_SFAEL  TO ITAB5_WRK-SKFOR,
             W_SNFAE  TO ITAB5_WRK-SKFOR.
        MODIFY ITAB5_WRK.
      ENDLOOP.
    FORM AGING.
      *CALL FUNCTION 'CUSTOMER_DUE_DATE_ANALYSIS'* 
      EXPORTING
          BUKRS             = P_COMP           
          KKBER             = WRK-KKBER
          KUNNR             = WRK-KUNNR
          RASID             = 'FEND'
          KLIMP             = 'X'
        IMPORTING
          SFAE1             = W_SFAE1
          SFAE2             = W_SFAE2
          SFAE3             = W_SFAE3
          SFAE4             = W_SFAE4
          SFAE5             = W_SFAE5
          SFAE6             = W_SFAE6
          SFAEL             = W_SFAEL
          SNFA1             = W_SNFA1
          SNFA2             = W_SNFA2
          SNFA3             = W_SNFA3
          SNFA4             = W_SNFA4
          SNFA5             = W_SNFA5
          SNFA6             = W_SNFA6
          SNFAE             = W_SNFAE
        EXCEPTIONS
          NO-AGING_SCHEDULE = 1
          NO_TABLE_INPUT    = 2.
      CASE SY-SUBRC.
        WHEN 1.
          MESSAGE E999 WITH 'PLEASE ENTER AGING SCHEDULE'.
        WHEN 2.
          MESSAGE E999 WITH 'DO NOTHING ??'.
      ENDCASE.
    ENDFORM.                    "AGING
    Thanks

  • How to read current line number in function module sourrce code?

    Hi All,
    How to read current line number in function module sourrce code?
    regards,
    Anuj

    If you have new editor you would be able to see the line number. 
    Or in the Dump screen - there is a button called Debugger - click that you would be able to see the code where dump has occured..  you would be able to find the line number from there.
    To get the new editor with line number , you need to change the settingsin SE38.
    Regards
    Vivek

  • How do we trap exception inside the function module?

    How do we trap exception inside the function module?

    Use ABAP Help - CATCH, RAISE for starters. Or take a look at an existing function module, for example.

  • How to call the Report program into Function module

    Hi Experts,
    Actually I want to create the DataSource. But I have only the ALV report program. I need to create function module but I don’t know how to call the ALV report program using in function module  
    So could you please any one send the Document or step by step method?
    Advance Thanks,
    Sathis

    If the report is just based out of a table than create a Generic Extractor using View.
    If its an InfoSet query than create a Generic Extractor on that InfoSet.
    If its an ABAP report than create a Generic Extractor using FM
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/a0f46157-e1c4-2910-27aa-e3f4a9c8df33

  • How to know whether the tables in function module is importing or exporting parameter?

    Hi guys,
    Why the tables are used in function modules, I knw it transfers internal tables, but thing is that how would i know instantly that whether table is getting imported or exported to the funtion module? Do i need to go through program flow or can we know just by seeing the function module?

    Hi anjali,
                   Tables are like multi line containers ,which can act as both import and export parameters .
                   means,the data in the table can be used by the function module during  its execution and the                same table can be populated with result after the fm execution .
      you can also refer :http://help.sap.com/saphelp_erp60_sp/helpdata/en/d1/801ece454211d189710000e8322d00/content.htm 
    Regards,
    Krishna.

  • How to insert a code for a function module into a Customer Exit Variable?

    I have two Key Figures viz., Net Prchs Rtl, and Net Prchs Unt. Both these Key figures have This Week (TW) and Last Week (LW). There is a variable for This week but there is no variable defined for Last week.
    I need to get data in the column LW (Last Week) for both the key figures.
    In function module EXIT_SAPLRRS0_001 one of the functions I have is:
    Get the previous Fiscal Week
              CALL FUNCTION 'DATE_TO_PERIOD_CONVERT'
    I need to create a new variable to get values in the Last week column for different key figures and use function “'DATE_TO_PERIOD_CONVERT'” in that variable.
    Can anyone please explain me the steps as to how to use a function module in a variable so that when the variable is used in a key figure it shows the output.
    In other words what I want to know is after creating a Customer exit variable of type Characteristic value how do I refer the above mentioned function moduel and insert the code for the function module into the Customer exit variable that I created.
    Thank you.
    TR.

    Hi Wond,
    Thanks a lot for your reply. I understand what you mean but I have never done this before so can you please explain it in a detailed manner. I have the following code:
    Get the previous Fiscal Week
              CALL FUNCTION 'DATE_TO_PERIOD_CONVERT'
                EXPORTING
                  i_date         = ld_date
                  i_periv        = lc_periv
                IMPORTING
                  e_buper        = ln_poper
                  e_gjahr        = ln_bdatj
                EXCEPTIONS
                  input_false    = 1
                  t009_notfound  = 2
                  t009b_notfound = 3
                  OTHERS         = 4.
              IF sy-subrc <> 0.
                MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
              ELSE.
                lc_poper = ln_poper.
                CONCATENATE ln_bdatj lc_poper+1(2) INTO wa_e_t_range-low.
                wa_e_t_range-sign = 'I'.
                wa_e_t_range-opt = 'EQ'.
                APPEND wa_e_t_range TO e_t_range.
              ENDIF.
            ENDIF.
          ENDIF.
        ENDIF.
    I believe I should now use the above code in my customer exit variable. If that's right can you please explain me the steps as to how should I do this so that the variable gets populated.
    Thank you.
    Regards,
    TR.

  • How to copy a generic extractor with function module into a new system?

    Dear Gurus,
    i would like to know how i can copy a gneric datasource with function module from one system to the target system.
    Thank you
    Cheers

    Hi Anesh,
    thank you for replying.
    Since the Datasource will have a new new in the new system, i will create a new one.
    Create a generic datasource base on the table is not the problem.
    My problem is how could i copy the FM in the new system?
    If you can help me on that, it will be fine.
    Thanks

  • How to extract the data by using function module?

    hi experts,
    what are the steps i have to fallow to extract the data from R/3 by using FUNCTION MODULE.
    thanks & regards
    venkat

    Hi,
    Extracting data from R/3 extract structure thru function modules
    You can proceed with create function module using SE37, thereu2019s sample in system RSAX_BIW_GET_DATA_SIMPLE,
    You need to know the logic how to populate the structure,
    after that RSO2, create datasource specify extract structure and
    function module,
    activate and replicate to bw.
    Chheers
    Raj

  • How to set lowercase/uppercase checkbox in function module/RFC

    Hi2All
    I m importing username and id in a RFC. i want this username as it is when we pass it in function module. if we set the check box lowercase/uppercase option when executing function module, it will keep all input as it is (means will not convert all inputs to CAP) .
    So how can i keep this chechboc checked forever for my RFC?
    Bye....!!!

    Hi,
    I don't think that's possible. I cannot able to find any SET/GET parameter assigned to it. If you are calling RFC from some other application, then you need to send your data as capital letters, or if it is custom RFC , then you can code into your code to convert small to capital letters. or if you are using a SAP standard then write wrapper function module.

  • Create BW datasource on standard ECC function module MCEX02_02_SCL_GR

    Hello Experts,
    I plan to use standard ECC function module MCEX02_02_SCL_GR to get the GR dates for the PO Schedule Lines. I copied this function module with the BW function group and tried to create a datasource in RSO2. However I receive the following error
    ZMM_PO_GR: TABLES-paramter E_T_DATA for extractor MCEX02_02_SCL_GR is missing
    I understand that the template for BW function modules is RSAX_BIW_GET_DATA_SIMPLE. However is there any way I can use the standard ECC function module OR else how would I incorporate the code in MCEX02_02_SCL_GR into the RSAX_BIW_GET_DATA_SIMPLE template.
    Thanks for your help.
    Alnick

    create a DS based on FM and call MCEX02_02_SCL_GR into that FM using call funcation XXX destination.
    or
    create a table in BW with fields Client, Source system and FM..and then do select statement toa take source system and give in palce of destination.

  • How to use a Logical Database in Function Module.

    Hi Experts,
    I want to use a logical database in a Function Module to fetch data from a standard SAP table into a Internal table for certain filter conditions.
    How can I get get this done????
    I called LDB_PROCESS FM in my FM, but I could not figure out how to store the extract in my IT table since we cant use GET in FM.
    Please provide me a sample code if possible.
    Thanks in Advance,
    Alex.

    Hi,
    i had an example program like this ,in this i want to get the data using pnp logical database with 5 fields in an interface program.
    data: begin of it_final occurs 0,
            pernr like pa0002-pernr,
            vorna like pa0002-vorna,
            nachn like pa0002-nachn,
           usrid like pa0105-usrid,
           usrid_long like pa0105-usrid_long,
           end of it_final.
    get pernr.
      clear : p0000,p0002,p0105.
      rp-provide-from-last p0000 space p_date p_date.
      if p0000-stat2 = '3'.
        v_pernr = pnppernr-low.
      else.
        reject.
      endif.
    *---Get employee pernr, First name ,Last name into final table
      rp-provide-from-last p0002 space p_date p_date.
      if pnp-sw-found = '1'.
       it_final-pernr = p0002-pernr.
       it_final-vorna = p0002-vorna.
       it_final-nachn = p0002-nachn.
      else.
    *---Error message if not infotype 0002 maintained
      T_ERROR-PERNR   = pnppernr-low.
      CONCATENATE TEXT-EMI '0002'
      INTO T_ERROR-MESSAGE SEPARATED BY SPACE.
      APPEND T_ERROR.
      CLEAR T_ERROR.
      endif.
    **--Get SYSTEM USERNAME to final table
      rp-provide-from-last p0105 0001 p_date p_date.
      if pnp-sw-found = '1'.
        it_final-usrid = p0105-usrid.
      else.
    *---Error message if not SYSTEM USERNAME maintained
        T_ERROR-PERNR   = pnppernr-low.
        CONCATENATE TEXT-003 '0105'
        INTO T_ERROR-MESSAGE SEPARATED BY SPACE.
        APPEND T_ERROR.
        CLEAR T_ERROR.
      endif.
    **--Get Email ID to final table
      rp-provide-from-last p0105 0010 p_date p_date.
      if pnp-sw-found = '1'.
        it_final-usrid_long = p0105-usrid_long.
      else.
    *---Error message if not Email ID maintained
        T_ERROR-PERNR   = pnppernr-low.
        CONCATENATE TEXT-004 '0105'
        INTO T_ERROR-MESSAGE SEPARATED BY SPACE.
        APPEND T_ERROR.
        CLEAR T_ERROR.
      endif.
       append it_final.
        clear it_final.
    reward points if useful,
    venkat.

  • How to pick the entries from a function  module fields values

    hi guys,
                i have a function module 'BP_JOBLOG_READ’.when i execute this for a particular jobname,i will get some entries.again if i click those entries,i will get some fields with values.in that one field 'text' contains total credit amount(purely numeric).how to fetch this value into internal tabel and update into my internal table.very urgent.plz provide some coding.rewards wil b there for helpful sggestion.

    Mahesh,
    Use the FM  BP_JOBLOG_SHOW  to display those job logs.
    Hope this is helpful.
    Thanks,
    Naren

Maybe you are looking for

  • Photoshop CC flickering on Macbook Pro?

    Hey guys. So I got a new Macbook Pro less than a month ago, mostly for drawing and such. I've encountered a problem, though, and that is that when I use Photoshop CC, the screen flickers! Not the entire screen, but the window in photoshop. This seems

  • Unknown error (-50) when opening itunes

    When I try to open itunes I get an error message (-50).  There is another user on my computer with MP3 Rocket could this be the problem?

  • Configration Server

    We have 5 SunOne Directory Server and they are using one Directory server as configration server. But I need reinstall OS on that server. How I can reconfigure all the DS servers to use another configration server or just use itself. Thanks.

  • Infoapckage schduling

    Hello Friends, Need some help. May be this is very simple question for you . Actually I have been scheduled one info package to run at one daily basis at 4.00 AM. Now I want to remove it from scheduling ( don’t want o run) , I have removed the option

  • Is it possible to have the background colour of a field change based on the entry?

    I previously obtained help from a user here to create a script that autopopulates a field based on options selected in two sets of radio buttons: var consequence = this.getField("Consequence").valueAsString;  var likelihood = this.getField("Likelihoo