Skip to Content

Generalised program for updating table thry ALV

Hi,

We have in production server there are some 1200 custom tables. We have requriement to create Table maintenance for all these tables.

My requirement is instead of creating table maintenance for all these tables, can you people have any generalised program to update these thru ALV .

please paste the code .

Thanks

aRs

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

8 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 09:01 PM

    Hello,

    Instead of creating Table Maintenance for 1500 Tables, Write a program with select-options program name and in the program call the FM 'VIEW_MAINTENANCE_CALL'.

    Hope my suggestion will fulfil your requirement.

    Reward Points, If helpful.

    Kannu.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 26, 2007 at 09:05 PM

    Kannu,

    Thanks for your reply.

    If you want to call table using VIEW_MAINTENANCE_CALL, then also we need to generate Table maintenace for tables.

    I like to avoid this , by creating a generalised program as Table Name as input and display in ALV ( with edit options) and save the table entries into table.

    If somebody come across this situation please paste the code

    Thanks

    aRs

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 09:05 PM

    Hi,

    You can try using the Function module STC1_FULLSCREEN_TABLE_CONTROL

    In that pass the table name in the parameter TABNAME

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 09:37 PM

    Hi,

    I will try creating this program..Question is ..Is just updating records is fine or you want to insert records also..

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 26, 2007 at 09:46 PM

    Hi Naren,

    Here some of the tables have T tables associated with them. In the case i could NOT able to use this function module STC1_FULLSCREEN_TABLE_CONTROL. Using this function module we can pass only one table at a time

    I think i have to write a dynamic ALV using OOps have to write.

    Thanks

    aRs

    Message was edited by:

    aRs

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 09:49 PM

    Hi,

    Yes...You can write an ALV program with the following steps..

    1) Create a dynamic internal table for the input table

    2) Get all the records from the table..Make the fields open for input..

    3) When the save button is pressed...save the values to the database..

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 10:26 PM

    Hi,

    You can use the Function module SE16N_INTERFACE..The sample code worked for me..

    PARAMETERS: P_TABLE TYPE DD02L-TABNAME.

    DATA: T_OUTPUT LIKE SE16N_OUTPUT OCCURS 0 WITH HEADER LINE.

    START-OF-SELECTION.

    SELECT FIELDNAME FROM DD03L INTO TABLE T_OUTPUT

    WHERE TABNAME = P_TABLE.

    IF SY-SUBRC <> 0.

    MESSAGE S208(00) WITH 'Table not found'.

    LEAVE LIST-PROCESSING.

    ENDIF.

    CALL FUNCTION 'SE16N_INTERFACE'

    EXPORTING

    i_tab = p_table

    I_EDIT = 'X'

    TABLES

    IT_OUTPUT_FIELDS = T_OUTPUT

    EXCEPTIONS

    NO_VALUES = 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.

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 26, 2007 at 10:29 PM

    Hi,

    Please try this and let me know..

    Thanks,

    Naren

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.