Get data from a module pool

Hello ABAP Experts,
I am BW person, and looking to extract the data from the table display from one of the trasactions in R/3.
tcode: fmderive
i checked the the program it is : SAPMABADR (module pool)
fields of hte table belong to: structure FMDERIVE
If i can get the data into a internal table. That would be great, i can do the rest of the processing before i extract this data to BW.
Any suggestions appreciated.
Thanks,
BWer

Hi,
It is possible to extract data in internal table. The internal table should be of a particular STRUCTURE which is created in SE11. Populate the internal table in program.
I do not remember the exact command, but it is somewhat as below. With this it is possible to extract data in BW.
*<QUERY HEAD> "Always comment this statement
loop at it_data into wa_data.
append wa_data to it_fmderive.
endloop.
*<QUERY BODY> "Always comment this statement
The internal table it_fmderive can be used to extract data in BW. This is the only way to extract data.
Also refer following link :
http://www.thespot4sap.com/articles/SAP_ABAP_Queries_DataRetrievalUsingProgram.asp
Best regards,
Prashant
Message was edited by: Prashant Patil

Similar Messages

  • How to get data from function module in crystal report

    Hi,
    I installed Crystal Reports 2008 and BO SAP Integration kit for CR.
    I connected successfully to SAP system from CR but unable to get the data into Report ...
    But data is present in function module.
    Could you please tell me what may be the reason ...!!
    Thanks
    Raghavendra

    Hi,
    I connected successfully to SAP system from CR but unable to get the data into Report with all the Input parameters and data is present in function module.
    Note: - If we take Start date as input parameter in Crystal report data is coming for single parameter, whereas we take input parameters like Partner function, Region and Customer - we are not getting data. (These fields we created parameters in Crystal report)
    In Function Module IMPORT Parameters are below mentioned and Export parameter is Blank
                                                                                    Start Date (Mandatory field)
                                                                                    Partner Function (Mandatory)
                                                                                    Region
                                                                                    Customer
    Please let us know if required any information.
    Regards,
    Raghavendra

  • Function module to get data from VARI table

    Hi All,
    thank you for viewing this thread. can anyone help me out in finding a function module which can get data from the VARI table?
    thank you

    Hi,
    FMs you will require are:
    RS_VARIANT_CONTENTS - Values of a variant returned in a table
    RS_VARIANT_EXISTS - Checks whether a variant exists for a report
    RS_VARIANT_TEXT - Returns short description of variant
    RS_VARIANT_VALUES_TECH_DATA - Reads variant parameters of a report
    Do search on them for complete details.
    Cheers.

  • Any Function module to get data from ESS leave form

    Hi Friends,
    I have modified std workflow ws12300111.with 2 levels.
    I want to send mail to HOD. In that mail i have to mention details like start date , end date,leave type which is entered into ESS form. I want to retrive that data.
    Is there any Fm is available? which wil give ESS data as output.
    Plz let m know.
    Regards,
    Shital

    Have you thought about creating attachments in the WF so you can read the form and get data from it.
    There's plenty of standard WF examples around of attaching objects to WF's.
    Since the ESS action will initiate the relevant workflows you should easily be able to save this data.
    BTW If your other question on this WF was answered please close that thread.
    Cheers
    Jimbo

  • Data insert through module pool programming

    hi
    I want to insert the data  into the data base through module pool programming.I am taking the fields from different tables, I need sample code ,please help me

    Hi Dhanunjay,
    REPORT zpe_str_le .
    TABLES : zpe_str , zprd_mis1 , mseg , t001l.
    *DATA : STR TYPE C VALUE '50'.
    data : text(100) VALUE 'DELETED STORAGE LOCATION NO '.
    SELECTION-SCREEN : BEGIN OF SCREEN 123 AS WINDOW TITLE TEXT-005.
    SELECT-OPTIONS : S_ZSLOC FOR ZPE_STR-ZSLOC,
    S_ZMACD FOR ZPE_STR-ZMACD,
    S_ZPGRP FOR ZPE_STR-ZPGRP.
    SELECTION-SCREEN : END OF SCREEN 123.
    DATA : flag(1) TYPE c,
    flag1 TYPE c ,
    flag3 TYPE c VALUE '1'.
    DATA : etab LIKE t001l OCCURS 0 WITH HEADER LINE.
    SELECT * FROM T001L INTO TABLE ETAB.
    DATA : ihead LIKE thead.
    DATA : prevtab LIKE tline OCCURS 0 WITH HEADER LINE.
    data : Jtab like TLINE occurs 0 with header line.
    DATA : jtab LIKE tline OCCURS 0 WITH HEADER LINE.
    DATA : itab LIKE zprd_mis1 OCCURS 0 WITH HEADER LINE.
    *SELECT * FROM zprd_mis1 INTO TABLE itab.
    DATA : BEGIN OF itab_sloc OCCURS 0,
    werks LIKE t001l-werks,
    lgort LIKE t001l-lgort,
    lgobe LIKE t001l-lgobe,
    END OF itab_sloc.
    *FLAG = 0.
    CALL SCREEN 100.
    MODULE user_command_0100 INPUT.
    CASE sy-ucomm.
    WHEN 'RET'.
    LEAVE TO LIST-PROCESSING AND RETURN TO SCREEN 100.
    *PERFORM PREVIEW.
    LOOP AT prevtab.
    WRITE : / prevtab.
    ENDLOOP.
    LOOP AT JTAB[] INTO ZPRD_MIS1.
    WRITE : Jtab-TDFORMAT.
    WRITE : Jtab-TDLINE .
    *********ZPRD_MIS1-MANDT = Jtab-TDLINE .
    *********ZPRD_MIS1-SLOC = Jtab-TDLINE .
    *********ZPRD_MIS1-MCODE = Jtab-TDLINE .
    *********ZPRD_MIS1-GCODE = Jtab-TDLINE .
    *********ZPRD_MIS1-DESCR = Jtab-TDLINE .
    *********INSERT ZPRD_MIS1.
    ENDLOOP.
    WRITE : JTAB-ZSLOC.
    *********CALL TRANSACTION 'SO10'.
    SET CURSOR 2 2.
    WHEN 'DET'.
    SELECT * FROM ZPRD_MIS1 INTO CORRESPONDING FIELDS OF TABLE ITAB.
    CALL SCREEN 123 STARTING AT 10 5.
    LEAVE TO LIST-PROCESSING AND RETURN TO SCREEN 0.
    SKIP 2 .
    WRITE :/1(8) 'STR.LOC' ,10(15) 'MRP. CTLR',27(10) 'P.GRP' ,39(40) 'DESCRIPTION OF PRODUCT'.
    SELECT SLOC MCODE GCODE DESCR FROM zprd_mis1 INTO ZPRD_MIS1 WHERE SLOC IN S_ZSLOC AND
    MCODE IN S_ZMACD AND
    GCODE IN S_ZPGRP.
    WRITE :/1(8) zprd_mis1-SLOC ,10(15) zprd_mis1-MCODE ,27(10) zprd_mis1-GCODE ,39(40) zprd_mis1-DESCR .
    ENDSELECT.
    WHEN 'CLEAR'.
    flag = 4.
    IF zpe_str-zsloc NE ' '.
    CLEAR zpe_str.
    ELSE.
    MESSAGE 'ALREADY CLEARED' TYPE 'S'.
    ENDIF.
    WHEN 'EXIT'.
    LEAVE TO SCREEN 0.
    WHEN 'SAVE'.
    IF zpe_str-zdesc NE ' '.
    IF zpe_str-zsloc NE ' '.
    LOOP AT itab.
    READ TABLE itab WITH KEY sloc = zpe_str-zsloc .
    IF sy-subrc = 0 AND flag = 5.
    zprd_mis1-mandt = sy-mandt.
    zprd_mis1-sloc = zpe_str-zsloc .
    zprd_mis1-mcode = zpe_str-zmacd .
    zprd_mis1-gcode = zpe_str-zpgrp.
    zprd_mis1-descr = zpe_str-zdesc .
    MODIFY zprd_mis1.
    flag1 = 7.
    MESSAGE 'STORAGE LOCATION MODIFIED' TYPE 'S'.
    EXIT.
    ELSE.
    zprd_mis1-mandt = sy-mandt.
    zprd_mis1-sloc = zpe_str-zsloc .
    zprd_mis1-mcode = zpe_str-zmacd .
    zprd_mis1-gcode = zpe_str-zpgrp.
    zprd_mis1-descr = zpe_str-zdesc .
    INSERT zprd_mis1.
    APPEND itab.
    flag = 5.
    flag1 = 7.
    MESSAGE 'STORAGE LOCATION CREATED' TYPE 'S'.
    *MESSAGE 'DATA ALREADY SAVED' TYPE 'S'.
    EXIT.
    *ENDIF.
    ENDIF.
    ENDLOOP.
    ELSE.
    flag = 3.
    MESSAGE 'PLEASE ENTER THE STORAGE LOCATION' TYPE 'S'.
    ENDIF.
    ELSE.
    LOOP AT itab.
    READ TABLE itab WITH KEY sloc = zpe_str-zsloc .
    IF sy-subrc = 0.
    MESSAGE 'ALREADY SAVED' TYPE 'S'.
    ELSE.
    MESSAGE 'ENTRIES FOR OTHER FIELDS REQUIRED' TYPE 'S'.
    ENDIF.
    ENDLOOP.
    ENDIF.
    WHEN 'CHECK'.
    SELECT * FROM zprd_mis1 INTO TABLE itab.
    IF zpe_str-zsloc NE ' '.
    LOOP AT itab.
    READ TABLE itab WITH KEY sloc = zpe_str-zsloc .
    IF sy-subrc = 0.
    zpe_str-zmandt = itab-mandt.
    zpe_str-zsloc = itab-sloc.
    zpe_str-zmacd = itab-mcode.
    zpe_str-zpgrp = itab-gcode.
    zpe_str-zdesc = itab-descr.
    flag = 7.
    flag1 = 7.
    ELSE.
    MESSAGE 'NO SUCH STORAGE LOCATION AVAILABLE' TYPE 'S'.
    EXIT.
    ENDIF.
    ENDLOOP.
    ELSE.
    flag = 3.
    MESSAGE 'PLEASE ENTER THE STORAGE LOCATION' TYPE 'S'.
    EXIT.
    ENDIF.
    WHEN 'DELETE'.
    IF zpe_str-zsloc EQ ' '.
    flag = 3.
    MESSAGE 'NOSUCH LOCATION AVAILABLE' TYPE 'S'.
    ELSE.
    READ TABLE itab WITH KEY sloc = zpe_str-zsloc .
    IF sy-subrc = 0.
    zpe_str-zmandt = itab-mandt.
    zpe_str-zsloc = itab-sloc.
    zpe_str-zmacd = itab-mcode.
    zpe_str-zpgrp = itab-gcode.
    zpe_str-zdesc = itab-descr.
    IF zpe_str-zsloc NE ' '.
    CALL FUNCTION 'G_CHECK_PASSWORD'
    EXPORTING
    password = 'PLANT1'
    EXCEPTIONS
    not_authorized = 1
    canceled = 2
    OTHERS = 3.
    IF sy-subrc = 0.
    PERFORM PREVIEW.
    DELETE FROM zprd_mis1 WHERE SLOC = zpe_str-zSLOC.
    UPDATE zprd_mis1.
    APPEND itab.
    MESSAGE 'STORAGE LOCATION DELETED' TYPE 'S'.
    ELSEIF SY-SUBRC = 2.
    MESSAGE 'OPRATION CANCELLED' TYPE 'E'.
    ELSEIF SY-SUBRC = 3.
    MESSAGE 'UNAUTHORIZED' TYPE 'E'.
    ENDIF.
    ELSE.
    MESSAGE 'STORAGE LOCATION CONTAINS NO DATA' TYPE 'S'.
    ENDIF.
    ELSE.
    MESSAGE 'STORAGE LOCATION CONTAINS NO DATA' TYPE 'S'.
    ENDIF.
    ENDIF.
    WHEN 'CREATE'.
    FLAG3 = 12.
    IF zpe_str-zsloc EQ ' '.
    MESSAGE 'ENTER THE STORAGE LOCATION' TYPE 'S'.
    EXIT.
    ELSE.
    LOOP AT etab.
    READ TABLE etab WITH KEY lgort = zpe_str-zsloc .
    IF sy-subrc = 0.
    read table itab with key sloc = zpe_str-zsloc .
    if sy-subrc = 0.
    zpe_str-zmandt = itab-mandt.
    zpe_str-zsloc = itab-sloc.
    zpe_str-zmacd = itab-mcode.
    zpe_str-zpgrp = itab-gcode.
    zpe_str-zdesc = itab-descr.
    flag = 7.
    flag1 = 7.
    clear flag .
    clear flag1.
    message 'storage location alredy exist' type 'S'.
    ELSE.
    FLAG = 2.
    MESSAGE 'STORAGE LOCATION ENTIRES DOESNOT EXIST' TYPE 'S'.
    ENDIF.
    else.
    message 'no such storage location exist' type 'S'.
    endif.
    endloop.
    FLAG = 2.
    exit.
    endif.
    WHEN 'CHANGE'.
    SELECT * FROM zprd_mis1 INTO TABLE itab.
    IF zpe_str-zsloc NE ' '.
    LOOP AT itab.
    READ TABLE itab WITH KEY sloc = zpe_str-zsloc .
    IF sy-subrc = 0.
    flag = 5.
    flag1 = 6.
    zpe_str-zmandt = itab-mandt.
    zpe_str-zsloc = itab-sloc.
    zpe_str-zmacd = itab-mcode.
    zpe_str-zpgrp = itab-gcode.
    zpe_str-zdesc = itab-descr.
    ELSE.
    MESSAGE 'NO STORAGE LOCATION AVAILABLE' TYPE 'S'.
    ENDIF.
    ENDLOOP.
    ELSE.
    flag = 3.
    MESSAGE 'PLEASE ENTER THE STORAGE LOCATION' TYPE 'S'.
    ENDIF.
    ENDCASE.
    ENDMODULE. " USER_COMMAND_0100 INPUT
    *& Module STATUS_0100 OUTPUT
    text
    MODULE status_0100 OUTPUT.
    SET PF-STATUS 'AAA'.
    SET TITLEBAR 'aaa'.
    IF flag3 = '1'.
    CALL FUNCTION 'G_CHECK_PASSWORD'
    EXPORTING
    password = 'PLANT1'
    EXCEPTIONS
    not_authorized = 1
    canceled = 2
    OTHERS = 3.
    IF sy-subrc 0.
    MESSAGE 'un authorized' TYPE 'S'(001).
    LEAVE TO SCREEN 0.
    ELSEIF SY-SUBRC = 2.
    MESSAGE ' OPERATION CANCELLED' TYPE 'S'(001).
    LEAVE TO SCREEN 0.
    ELSEIF SY-SUBRC = 3.
    LEAVE TO SCREEN 0.
    MESSAGE 'RESTRICTED' TYPE 'S'(001).
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CLEAR flag3.
    ENDIF.
    SELECT * FROM zprd_mis1 INTO TABLE itab.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    IF flag = 5 AND flag1 EQ 6.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 1.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'DELETE' OR screen-name = 'CHANGE' OR screen-name = 'CHECK'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    EXIT.
    ENDIF.
    IF flag = 2.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 1.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'DELETE' OR screen-name = 'CHANGE' OR screen-name = 'CHECK'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    EXIT.
    ENDIF.
    IF flag3 = 12.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 1.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'DELETE' OR screen-name = 'CHANGE' OR screen-name = 'RET' OR screen-name = 'CHECK'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    EXIT.
    CLEAR FLAG3.
    ENDIF.
    IF flag = 4.
    IF screen-name CP 'ZPE_*'.
    screen-input = 1.
    ENDIF.
    ENDIF.
    IF flag1 = 7 AND flag = 5.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZSLOC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'DELETE' OR screen-name = 'CHECK' OR screen-name = 'SAVE'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    IF flag1 = 7 AND flag = 7.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZSLOC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'CHECK' OR screen-name = 'SAVE'." OR screen-name = 'DELETE'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    IF flag1 = 4 AND flag = 3.
    LOOP AT SCREEN.
    IF screen-name = 'ZPE_STR-ZDESC' OR screen-name = 'ZPE_STR-ZSLOC' OR screen-name = 'ZPE_STR-ZPGRP' OR screen-name = 'ZPE_STR-ZMACD'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    IF screen-name = 'CREATE' OR screen-name = 'SAVE' OR screen-name = 'DELETE' OR screen-name = 'CHANGE' OR screen-name = 'CHECK'.
    screen-input = 0.
    MODIFY SCREEN.
    ENDIF.
    ENDLOOP.
    ENDIF.
    ENDMODULE. " STATUS_0100 OUTPUT
    DATA: BEGIN OF r1 OCCURS 1.
    INCLUDE STRUCTURE ddshretval.
    DATA: END OF r1.
    *& Module VALUE_SLOC INPUT
    text
    MODULE value_sloc INPUT.
    SELECT lgort werks lgobe FROM t001l INTO CORRESPONDING FIELDS OF TABLE itab_sloc.
    DELETE ADJACENT DUPLICATES FROM itab_sloc COMPARING lgort.
    CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
    EXPORTING
    retfield = 'LGORT'
    value_org = 'S'
    TABLES
    value_tab = itab_sloc
    return_tab = r1
    EXCEPTIONS
    parameter_error = 1
    no_values_found = 2
    OTHERS = 3.
    IF sy-subrc EQ 0.
    IF r1-fieldval IS NOT INITIAL.
    zpe_str-zsloc = r1-fieldval.
    ENDIF.
    ENDIF.
    EXIT.
    *ENDSELECT.
    ENDMODULE. " VALUE_SLOC INPUT
    FORM PREVIEW.
    *TABLES : ZPE_STR , ZPRD_MIS1 , MSEG.
    data : ihead like thead.
    DATA : prevtab like TLINE occurs 0 with header line.
    data : Jtab like TLINE occurs 0 with header line.
    *data : Jtab like thead occurs 0 with header line.
    *data : text(100).
    CALL FUNCTION 'READ_TEXT'
    EXPORTING
    CLIENT = SY-MANDT
    ID = 'ST'
    LANGUAGE = sy-langu
    NAME = 'ZSLDEL'
    OBJECT = 'TEXT'
    ARCHIVE_HANDLE = 0
    LOCAL_CAT = ' '
    IMPORTING
    HEADER =
    TABLES
    LINES = prevtab[]
    EXCEPTIONS
    ID = 1
    LANGUAGE = 2
    NAME = 3
    NOT_FOUND = 4
    OBJECT = 5
    REFERENCE_CHECK = 6
    WRONG_ACCESS_TO_ARCHIVE = 7
    OTHERS = 8
    IF SY-SUBRC 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    if not prevtab[] is initial.
    append lines of prevtab to jtab.
    endif.
    *IHEAD-TDFDATE = SY-DATUM.
    *IHEAD-TDFTIME = SY-UZEIT.
    ihead-TDOBJECT = 'TEXT'.
    ihead-TDNAME = 'ZSLDEL'.
    ihead-TDID = 'ST'.
    ihead-TDSPRAS = sy-langu.
    type-pools : slis.
    Jtab-TDFORMAT = ''.
    *Jtab-TDLINE = 'SLOCATION'.
    *append Jtab.
    *Jtab-TDFORMAT = ''.
    Jtab-TDFORMAT = '*'.
    Jtab-TDLINE = ZPE_STR-ZSLOC.
    append Jtab.
    Jtab-TDFORMAT = ''.
    *Jtab-TDLINE = 'DATE'.
    *append Jtab.
    Jtab-TDFORMAT = ''.
    *Jtab-TDLINE = SY-DATUM.
    *append Jtab.
    Jtab-TDFORMAT = ''.
    *Jtab-TDLINE = 'TIME'.
    *append Jtab.
    Jtab-TDFORMAT = ''.
    *Jtab-TDLINE = SY-UZEIT.
    *Jtab-TDFORMAT = ''.
    *append Jtab.
    CALL FUNCTION 'SAVE_TEXT'
    EXPORTING
    CLIENT = SY-MANDT
    HEADER = ihead
    INSERT = 'X'
    SAVEMODE_DIRECT = ' '
    OWNER_SPECIFIED = ' '
    LOCAL_CAT = ' '
    IMPORTING
    FUNCTION =
    NEWHEADER =
    TABLES
    LINES = Jtab
    EXCEPTIONS
    ID = 1
    LANGUAGE = 2
    NAME = 3
    OBJECT = 4
    OTHERS = 5
    IF SY-SUBRC 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CALL FUNCTION 'COMMIT_TEXT'
    EXPORTING
    OBJECT = '*'
    NAME = '*'
    ID = '*'
    LANGUAGE = '*'
    SAVEMODE_DIRECT = ' '
    KEEP = ' '
    LOCAL_CAT = ' '
    IMPORTING
    COMMIT_COUNT =
    TABLES
    T_OBJECT =
    T_NAME =
    T_ID =
    T_LANGUAGE =
    ENDFORM.
    *&spwizard: declaration of tablecontrol 'TBLECTL' itself
    controls: TBLECTL type tableview using screen 0100.
    *&spwizard: lines of tablecontrol 'TBLECTL'
    data: g_TBLECTL_lines like sy-loopc.
    data: OK_CODE like sy-ucomm.
    *&spwizard: output module for tc 'TBLECTL'. do not change this line!
    *&spwizard: update lines for equivalent scrollbar
    module TBLECTL_change_tc_attr output.
    describe table ITAB lines TBLECTL-lines.
    endmodule.
    *&spwizard: output module for tc 'TBLECTL'. do not change this line!
    *&spwizard: get lines of tablecontrol
    module TBLECTL_get_lines output.
    g_TBLECTL_lines = sy-loopc.
    endmodule.
    *&spwizard: input module for tc 'TBLECTL'. do not change this line!
    *&spwizard: process user command
    module TBLECTL_user_command input.
    OK_CODE = sy-ucomm.
    perform user_ok_tc using 'TBLECTL'
    'ITAB'
    changing OK_CODE.
    sy-ucomm = OK_CODE.
    endmodule.
    INCLUDE TABLECONTROL_FORMS *
    *& Form USER_OK_TC *
    FORM USER_OK_TC USING P_TC_NAME TYPE DYNFNAM
    P_TABLE_NAME
    P_MARK_NAME
    CHANGING P_OK LIKE SY-UCOMM.
    &SPWIZARD: BEGIN OF LOCAL DATA----
    DATA: L_OK TYPE SY-UCOMM,
    L_OFFSET TYPE I.
    &SPWIZARD: END OF LOCAL DATA----
    *&SPWIZARD: Table control specific operations *
    *&SPWIZARD: evaluate TC name and operations *
    SEARCH P_OK FOR P_TC_NAME.
    IF SY-SUBRC 0.
    EXIT.
    ENDIF.
    L_OFFSET = STRLEN( P_TC_NAME ) + 1.
    L_OK = P_OK+L_OFFSET.
    *&SPWIZARD: execute general and TC specific operations *
    CASE L_OK.
    WHEN 'INSR'. "insert row
    PERFORM FCODE_INSERT_ROW USING P_TC_NAME
    P_TABLE_NAME.
    CLEAR P_OK.
    WHEN 'DELE'. "delete row
    PERFORM FCODE_DELETE_ROW USING P_TC_NAME
    P_TABLE_NAME
    P_MARK_NAME.
    CLEAR P_OK.
    WHEN 'P--' OR "top of list
    'P-' OR "previous page
    'P+' OR "next page
    'P++'. "bottom of list
    PERFORM COMPUTE_SCROLLING_IN_TC USING P_TC_NAME
    L_OK.
    CLEAR P_OK.
    WHEN 'L--'. "total left
    PERFORM FCODE_TOTAL_LEFT USING P_TC_NAME.
    WHEN 'L-'. "column left
    PERFORM FCODE_COLUMN_LEFT USING P_TC_NAME.
    WHEN 'R+'. "column right
    PERFORM FCODE_COLUMN_RIGHT USING P_TC_NAME.
    WHEN 'R++'. "total right
    PERFORM FCODE_TOTAL_RIGHT USING P_TC_NAME.
    WHEN 'MARK'. "mark all filled lines
    PERFORM FCODE_TC_MARK_LINES USING P_TC_NAME
    P_TABLE_NAME
    P_MARK_NAME .
    CLEAR P_OK.
    WHEN 'DMRK'. "demark all filled lines
    PERFORM FCODE_TC_DEMARK_LINES USING P_TC_NAME
    P_TABLE_NAME
    P_MARK_NAME .
    CLEAR P_OK.
    WHEN 'SASCEND' OR
    'SDESCEND'. "sort column
    PERFORM FCODE_SORT_TC USING P_TC_NAME
    l_ok.
    ENDCASE.
    ENDFORM. " USER_OK_TC
    *& Form FCODE_INSERT_ROW *
    FORM fcode_insert_row
    USING P_TC_NAME TYPE DYNFNAM
    P_TABLE_NAME .
    &SPWIZARD: BEGIN OF LOCAL DATA----
    DATA L_LINES_NAME LIKE FELD-NAME.
    DATA L_SELLINE LIKE SY-STEPL.
    DATA L_LASTLINE TYPE I.
    DATA L_LINE TYPE I.
    DATA L_TABLE_NAME LIKE FELD-NAME.
    FIELD-SYMBOLS <TC> TYPE CXTAB_CONTROL.
    FIELD-SYMBOLS <TABLE> TYPE STANDARD TABLE.
    FIELD-SYMBOLS <LINES> TYPE I.
    &SPWIZARD: END OF LOCAL DATA----
    ASSIGN (P_TC_NAME) TO <TC>.
    *&SPWIZARD: get the table, which belongs to the tc *
    CONCATENATE P_TABLE_NAME '[]' INTO L_TABLE_NAME. "table body
    ASSIGN (L_TABLE_NAME) TO <TABLE>. "not headerline
    *&SPWIZARD: get looplines of TableControl *
    CONCATENATE 'G_' P_TC_NAME '_LINES' INTO L_LINES_NAME.
    ASSIGN (L_LINES_NAME) TO <LINES>.
    *&SPWIZARD: get current line *
    GET CURSOR LINE L_SELLINE.
    if sy-subrc 0. " append line to table
    l_selline = <tc>-lines + 1.
    *&SPWIZARD: set top line *
    if l_selline > <lines>.
    <tc>-top_line = l_selline - <lines> + 1 .
    else.
    <tc>-top_line = 1.
    endif.
    else. " insert line into table
    l_selline = <tc>-top_line + l_selline - 1.
    l_lastline = <tc>-top_line + <lines> - 1.
    endif.
    *&SPWIZARD: set new cursor line *
    l_line = l_selline - <tc>-top_line + 1.
    *&SPWIZARD: insert initial line *
    INSERT INITIAL LINE INTO <TABLE> INDEX L_SELLINE.
    <TC>-LINES = <TC>-LINES + 1.
    *&SPWIZARD: set cursor *
    SET CURSOR LINE L_LINE.
    ENDFORM. " FCODE_INSERT_ROW
    *& Form FCODE_DELETE_ROW *
    FORM fcode_delete_row
    USING P_TC_NAME TYPE DYNFNAM
    P_TABLE_NAME
    P_MARK_NAME .
    &SPWIZARD: BEGIN OF LOCAL DATA----
    DATA L_TABLE_NAME LIKE FELD-NAME.
    FIELD-SYMBOLS <TC> TYPE cxtab_control.
    FIELD-SYMBOLS <TABLE> TYPE STANDARD TABLE.
    FIELD-SYMBOLS <WA>.
    FIELD-SYMBOLS <MARK_FIELD>.
    &SPWIZARD: END OF LOCAL DATA----
    ASSIGN (P_TC_NAME) TO <TC>.
    *&SPWIZARD: get the table, which belongs to the tc *
    CONCATENATE P_TABLE_NAME '[]' INTO L_TABLE_NAME. "table body
    ASSIGN (L_TABLE_NAME) TO <TABLE>. "not headerline
    *&SPWIZARD: delete marked lines *
    DESCRIBE TABLE <TABLE> LINES <TC>-LINES.
    LOOP AT <TABLE> ASSIGNING <WA>.
    *&SPWIZARD: access to the component 'FLAG' of the table header *
    ASSIGN COMPONENT P_MARK_NAME OF STRUCTURE <WA> TO <MARK_FIELD>.
    IF <MARK_FIELD> = 'X'.
    DELETE <TABLE> INDEX SYST-TABIX.
    IF SY-SUBRC = 0.
    <TC>-LINES = <TC>-LINES - 1.
    ENDIF.
    ENDIF.
    ENDLOOP.
    ENDFORM. " FCODE_DELETE_ROW
    *& Form COMPUTE_SCROLLING_IN_TC
    text
    -->P_TC_NAME name of tablecontrol
    -->P_OK ok code
    FORM COMPUTE_SCROLLING_IN_TC USING P_TC_NAME
    P_OK.
    &SPWIZARD: BEGIN OF LOCAL DATA----
    DATA L_TC_NEW_TOP_LINE TYPE I.
    DATA L_TC_NAME LIKE FELD-NAME.
    DATA L_TC_LINES_NAME LIKE FELD-NAME.
    DATA L_TC_FIELD_NAME LIKE FELD-NAME.
    FIELD-SYMBOLS <TC> TYPE cxtab_control.
    FIELD-SYMBOLS <LINES> TYPE I.
    &SPWIZARD: END OF LOCAL DATA----
    ASSIGN (P_TC_NAME) TO <TC>.
    *&SPWIZARD: get looplines of TableControl *
    CONCATENATE 'G_' P_TC_NAME '_LINES' INTO L_TC_LINES_NAME.
    ASSIGN (L_TC_LINES_NAME) TO <LINES>.
    *&SPWIZARD: is no line filled? *
    IF <TC>-LINES = 0.
    *&SPWIZARD: yes, ... *
    L_TC_NEW_TOP_LINE = 1.
    ELSE.
    *&SPWIZARD: no, ... *
    CALL FUNCTION 'SCROLLING_IN_TABLE'
    EXPORTING
    ENTRY_ACT = <TC>-TOP_LINE
    ENTRY_FROM = 1
    ENTRY_TO = <TC>-LINES
    LAST_PAGE_FULL = 'X'
    LOOPS = <LINES>
    OK_CODE = P_OK
    OVERLAPPING = 'X'
    IMPORTING
    ENTRY_NEW = L_TC_NEW_TOP_LINE
    EXCEPTIONS
    NO_ENTRY_OR_PAGE_ACT = 01
    NO_ENTRY_TO = 02
    NO_OK_CODE_OR_PAGE_GO = 03
    OTHERS = 0.
    ENDIF.
    *&SPWIZARD: get actual tc and column *
    GET CURSOR FIELD L_TC_FIELD_NAME
    AREA L_TC_NAME.
    IF SYST-SUBRC = 0.
    IF L_TC_NAME = P_TC_NAME.
    *&SPWIZARD: et actual column *
    SET CURSOR FIELD L_TC_FIELD_NAME LINE 1.
    ENDIF.
    ENDIF.
    *&SPWIZARD: set the new top line *
    <TC>-TOP_LINE = L_TC_NEW_TOP_LINE.
    ENDFORM. " COMPUTE_SCROLLING_IN_TC
    *& Form FCODE_TC_MARK_LINES
    marks all TableControl lines
    -->P_TC_NAME name of tablecontrol
    FORM FCODE_TC_MARK_LINES USING P_TC_NAME
    P_TABLE_NAME
    P_MARK_NAME.
    &SPWIZARD: EGIN OF LOCAL DATA----
    DATA L_TABLE_NAME LIKE FELD-NAME.
    FIELD-SYMBOLS <TC> TYPE cxtab_control.
    FIELD-SYMBOLS <TABLE> TYPE STANDARD TABLE.
    FIELD-SYMBOLS <WA>.
    FIELD-SYMBOLS <MARK_FIELD>.
    &SPWIZARD: END OF LOCAL DATA----
    ASSIGN (P_TC_NAME) TO <TC>.
    *&SPWIZARD: get the table, which belongs to the tc *
    CONCATENATE P_TABLE_NAME '[]' INTO L_TABLE_NAME. "table body
    ASSIGN (L_TABLE_NAME) TO <TABLE>. "not headerline
    *&SPWIZARD: mark all filled lines *
    LOOP AT <TABLE> ASSIGNING <WA>.
    *&SPWIZARD: access to the component 'FLAG' of the table header *
    ASSIGN COMPONENT P_MARK_NAME OF STRUCTURE <WA> TO <MARK_FIELD>.
    <MARK_FIELD> = 'X'.
    ENDLOOP.
    ENDFORM. "fcode_tc_mark_lines
    *& Form FCODE_TC_DEMARK_LINES
    demarks all TableControl lines
    -->P_TC_NAME name of tablecontrol
    FORM FCODE_TC_DEMARK_LINES USING P_TC_NAME
    P_TABLE_NAME
    P_MARK_NAME .
    &SPWIZARD: BEGIN OF LOCAL DATA----
    DATA L_TABLE_NAME LIKE FELD-NAME.
    FIELD-SYMBOLS <TC> TYPE cxtab_control.
    FIELD-SYMBOLS <TABLE> TYPE STANDARD TABLE.
    FIELD-SYMBOLS <WA>.
    FIELD-SYMBOLS <MARK_FIELD>.
    &SPWIZARD: END OF LOCAL DATA----
    ASSIGN (P_TC_NAME) TO <TC>.
    *&SPWIZARD: get the table, which belongs to the tc *
    CONCATENATE P_TABLE_NAME '[]' INTO L_TABLE_NAME. "table body
    ASSIGN (L_TABLE_NAME) TO <TABLE>. "not headerline
    *&SPWIZARD: demark all filled lines *
    LOOP AT <TABLE> ASSIGNING <WA>.
    *&SPWIZARD: access to the component 'FLAG' of the table header *
    ASSIGN COMPONENT P_MARK_NAME OF STRUCTURE <WA> TO <MARK_FIELD>.
    <MARK_FIELD> = SPACE.
    ENDLOOP.
    ENDFORM. "fcode_tc_mark_lines
    Source : https://forums.sdn.sap.com/click.jspa?searchID=15092700&messageID=5654151
    Have A Good Day
    Chaitanya.

  • How to get data from hard drive in dead iMac?

    I have an old slot-loading iMac (350Mhz G3 blueberry) that just died, probably a dead power supply or something. Won't turn on at all. I don't care about restoring it, I just want to take the hard drive out and grab data from it. I've found instructions for removing the HD ... but any tips on the best/cheapest way to hook it up to get data from it? It's EIDE I believe from what I've read so far. Thanks for any help.

    Hey Richard.....Thanks for the reply to my question about my wife's dead iMac.....
    Her iMac had been acting up lately, mostly to do with her Outlook Express freezing up in OS9. I dunno if OS9 was freezing or if the application was failing. Regardless, I would have to quit OS9, restart Outlook which at the same time restarted OS9. All would be fine for a while, a day or two and then the scene would repeat itself. But I think that issue is separate from the iMac being "dead". Often we have power outages in the area, more than we should. I had the iMac plugged into a battery backup, some APS product I think it is. I believe it is only good for less than an hour as we have other devices drawing on it too. Most of our power outages are of short duration, just enough to be aggravating, sometimes having to reset clocks, etc...And a couple times, I would have to reset the time and date on the iMac so this told me that the PRAM battery was below minimum voltage. But the iMac would ALWAYS restart, even with the low battery. But the most recent outage, about one hour duration, did in the iMac, somehow or other. I do believe the battery backup basically fully discharged. So I removed the battery, could not find a new battery locally so I drove to the big city and paid the local Apple service dealer a visit. I got ripped big time price wise, embarrassed to say. So I get home, put the battery in the holder, depressed the CMU reset, the powerbutton illuminated as did a green LED by the memory modules for less than three seconds and then quit. I also heard the HD trying to spin up and a high voltage THUMP which I assume is the CRT trying to ignite. If I unplugged the iMac, removed the battery, plug in the power again and hit the power button, the iMac would repeat the same short on period and then quit. So it did not seem to make any difference if there was a battery in place. I read somewhere to pull the battery, pull the AC cord, hold down the power button to dump any current (?) and let the unit sit for 24hrs. After that length of time, I was supposed to replace the battery, depress the CMU reset, wait ten seconds and then feed it AC. Well, when I pressed the power button, I heard life for maybe five seconds, maybe a second longer, then a beep and then it shut down. I pulled the AC cord, pulled the battery, re-inserted the battery, depressed the CMU reset, waited a few seconds, plugged in the AC cord, depressed the power button and I am back at the under three seconds of "power-up" and then nothing, dead, no beep, nothing. I think maybe it is a waste of time trying to mess with this unit, looking for a newer iMac on eBay, the snowball series with the 17" LCD, might be time better spent. Hate throwing stuff away, that's why I am up to my ears in junk, maybe u know that scenario. The wife likes my 19" ACER LCD screen, hooked up to this old dual 800mhz, though she dislikes the noise and the tower. But we both agree the large LCD screen is much easier on our aging eyes than the old iMac CRT. Anyway, I appreciate your help, always GREAT to correspond with an Apple fan.....John Bauer

  • How can i get data from the other system?

    hi,
    i want get some data from the other r3 system in my r3 system? now this two r3 system are installed two server.

    Hi,
    U can achieve this by RFC function module...
    create a function module and make it as REMOTE ENEBLED IN ATTRIBUTES TAB..
    for example i have to r/3 systems as A and B.
    I want to get data from B system..
    so create the FM in B system and then in A SYSTEM u have to call that one ,like this....
    DESTINATION NAME IS FOR SYSTEM B.
    CALL FUNCTION 'ZRFC' DESTINATION <DESTINATION NAME>
    EXPORTING
    IMPORTING
    TABLES..
    Regards,
    Nagaraj

  • Get data from Sharepoint site in different farm using webservice, and current site using claims mode authentication.

    Hi , 
    I have a site that runs on   Claims Mode (  NTLM) . That site has a web part that needs to show the data from any  sharepoint farm, SharePoitn  2010 , or 2007 or 2003.
    I am getting 401 unauthorized when I   try to get data from webservice running in sharePoint context.
    But when I run the same code in  Windows Console application  then it is giving no error.
    What I doubt is that this issue is due to the reason that I have  set
    claims mode authentication.
    Because same code is running  in different farm in a site that is configured  using windows authentication.

    So generally speaking, you're talking about a VERY long running topic of authentication methods... and generally speaking, in the world of Windows, the only long running authentication options have been:
    - NTLM (limited to one hop)
    - Kerberos (unlimited hops)
    - Application level authentication (ex: SQL auth, also, no hops)
    Recently, Microsoft has been investing in Claims Based Auth... and I fully expect claims to start working their way into other systems (previously starting to work into Windows via the CardSpace technology, but also in other ways such as Win8's ability to
    log in with a LiveID)... but building a new authentication method into ALL applications is a VERY long process, and the complexity of claims adds a LOT of consideration (claims from the same AD can look VERY different depending on the STS, so lots of questions
    around things like bridging claims).
    So as far your SP auth needs...
    IF both applications are CLAIMS AWARE, then you MAY be able to use claims (which support unlimited hops)... but that's just not very likely yet (and will probably take another 5-10 years to be available across the entire enterprise)... otherwise, KERBEROS
    Outside of the Microsoft world... KERBEROS is open spec, so is supported by other systems (such as authenticating to linux)... claims based auth is also open spec, but again, still new... there are a few other options (LDAP, etc), but none that are native
    to Windows (so you rely on things like third party auth modules for Windows, which Novell has done for DECADES with NDS and eDir)
    And again, SharePoint can convert claims to Kerberos using the C2WTS... which MS uses internally for things Excel Services connecting to a backend SQL server... but it DOES require the Kerb and C2WTS configuration.
    if you're having issues using Kerb auth... then it sounds like Kerb isn't configured correctly... and Kerb is a PAIN to configure (whitepaper for SP Kerb is ~100 pages long)... IIS (and SharePoint) also has the added benefit of failing over to NTLM if Kerb
    fails (and you shouldn't disable this behavior, since it'll break other settings elsewhere)
    Scott Brickey
    MCTS, MCPD, MCITP
    www.sbrickey.com
    Strategic Data Systems - for all your SharePoint needs

  • How to get data from structures ??

    HI
    I have to do a report.I had given structures instead of display tables.we cant get data from the structures. are there any FM to diaplay data from structures or shd i need to sreach the fileds in display table
    Regards
    Rasheed

    Hi,
    There are several ways to find the tables:
    1) Choose the data elements that the structure fields belong to - do a 'Where User' in SE11 to see any tables - check using SE16.
    2) Use ST05 and or SE30 to trace the transaction and see what tables are being read.
    3) In many areas there are Function Modules that does these reads - could you please provide more details of the area you are trying to get data from?

  • Adobe form getting data from BADI?

    Hi,
    I  have a webdynpro component which calls an Adobe form which gets data from BADI i.e. prepoulate the values after interacting with the BADI's.How to find the BADI's name ?how it triggers that particular BADI.where it is calling exit handler?
    please reply me soon..
    Regards,
    Lakshmi.

    >
    Lakshmi Atukury wrote:
    > Hi,
    > adobe form getting data from BADI only,through the BADI interface method Initialize.
    > but technically i would like to know from where it is calling BADI and how it interacts with Adobe form.How the process goes?
    >
    > Regards,
    > Lakshmi.
    That's why we have debuggers.  I suggest that you start debugging through the application and see what it is going on. I would find it difficult to see how the Form itself calls a BADI (since a BADI is an exit in ABAP coding).  I would think that the BADI would be called via a service class of the Web Dynpro or the Web Dynpro is calling a function module to process the form.  I would start back with the Web Dynpro and see how it is even initializing the form itself.

  • Date field in module pool

    hi all,
    i want to have date field in module pool with F4 help. m keeping format as DATS. but still its not taking F4 help for taking date from calender...how shud i do it.

    Call this FM -
    CALL FUNCTION 'F4_DATE'
           EXPORTING
                DATE_FOR_FIRST_MONTH = DATE
                DISPLAY              = HELPDISP
           IMPORTING
                SELECT_DATE          = DATE
           EXCEPTIONS
                OTHERS               = 4.
    Regards,
    Amit
    Reward all helpful replies.

  • Clarification on details regarding getting data from APO into BW

    Hi Friends,
    I need some clarification in terms of getting data from APO into BW for reporting:
    I observed that SAP has provided standard data flows for PPDS module, where as for the Demand Planning and Supply Network Planning SAP has just provided some standard InfoCubes ex: 0APO_C07, 0APO_C10, 0APO_C11, 0APO_C12.
    Which makes me believe that for Demand Planning and Supply Network Planning we need to generate DataSources from the Planning books in DP & SNP and build our own custom data flows. In that case what is the use of above mentioned InfoCubes provided by SAP?
    Also in my current project the client has built a custom DataSource on top of a Planning Book in DP and created custom data flow in BW for reporting and also created a Back up cube in APO.
    My question on this is, what is the use of this Back up cube in APO, what is the need to maintain two same cubes in two different systems?
    My next question is, I have installed complete data flow for 0APO_C02 (Orders Data) in BW and loaded data. In SAP documentation it says when we try to load data for a particular date range using this InfoSource (0APO_PPDS_ORDER_01), it directly loads data from the live cache.
    Is there a way to know if the data is coming from Live Cache or from APO server, can we get data from live cache for 9A*** Datasources also, which we create on planning books in DP and SNP?
    Any comments and Info will be greatly appreciated. Thanks!

    Hi Sunitha, thanks for your inputs. So does that mean for Demand Planning and Supply Network Planning, SAP has not given any standard DataSources because it makes more sense to build DataSources from the planning books as each company has their own planning strategies based on how they do there business. Right?
    And for these modules there is no other way rather than generating DataSources from Planning Books and build the Data Flows based on it. Right?
    Also these generated DataSources i.e. 9A**** pull data from live cache itself right or is there any setting that we need to enable for it to get data from live cache?
    Thanks again for your valuable inputs hope to get answers to above questions as well.

  • Who worked with ICS' Model 4896 GPIB? I can not count the data from the module. Can prompt as it to make. It is desirable with examples (data read-out from the module and data transmission between channels. It is in advance grateful.

    I can not count the data from the module. Can prompt as it to make. It is desirable with examples (data read-out from the module and data transmission between channels. It is in advance grateful.

    Hello. Most of the engineers in developer exchange are more familiar
    with NI products. Contacting ICS for technical support is a better
    course of action.

  • Can we get data from business views  in CR 2008/XI?

    Hi All,
    Can we get data from business views  in CR 2008/XI?
    If its possible, pls let us know how to get connect with Business View in both of these versions and what is the tool that we have to use to create Business Views.
    Thank you,
    Krishna Pingali

    Hi Krishna,
    Crystal Reports/BusinessObjects Enterprise ( BOE ) Business Views can only be created using the BV build which comes with BOE and installed using the Work Station installer for BOE. for both XI and 2008.
    You cannot mix these two versions on the same PC not can one talk to the other, the BV designer must match the same version as BOE. XI ( version 11.0 ) is no longer available but if you mean XI R2 ( version 11.5 ) then it still is.
    It's not completely clear which Business View you are referring to? BOE has a Business View Designer so not sure if this is just a naming problem or not? If you are referring to the BOE Business View Designer then the above is true. If your reference is about some other BV designer or data source then you need to clarify.
    Contact our Sales department for pricing and availability.
    Thank you
    Don

  • Funds management cube getting data from 4 ods, data not seen in cube

    Hello all,
    I am working on funds management cubes (0PU_C02 and 0PU_C03). These two cubes get data from like 7 or 8 ODS. Can someone tell me which are the ODS which feed to respective cubes. I have the mappings done but i am getting very confused.
    In the ods 0PU_O44 there is RLDNR for Ledger and I can see that data in ODS but when i run load to cube I dont see the ledger data (its direct mapping there are no routines or rules).
    Is there any sequence with wihic we have to load the data?
    Thanks
    Message was edited by: Raj M

    Hi Raj,
    I was going thru the forums who has knowledge in Public sector when i came accross ur forum.Can i get your email id..i have some questions to ask regarding student administration.
    thanks.

Maybe you are looking for