<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic creating multiple dynamic internal tables in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084356#M432680</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have requirement where the user is going to enter the table names in the select-option note its not parameter its select option so the user can enter more than one table name. so based on this tables how do i create multiple dynamic internal table names.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Neha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 03 Apr 2007 10:58:33 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-03T10:58:33Z</dc:date>
    <item>
      <title>creating multiple dynamic internal tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084356#M432680</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have requirement where the user is going to enter the table names in the select-option note its not parameter its select option so the user can enter more than one table name. so based on this tables how do i create multiple dynamic internal table names.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Neha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Apr 2007 10:58:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084356#M432680</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-03T10:58:33Z</dc:date>
    </item>
    <item>
      <title>Re: creating multiple dynamic internal tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084357#M432681</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt; Check the below program to create dynamic internal table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zcdf_dynamic_table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Dynamic ALV Grid with Cell Coloring.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; Build a field catalog dynamically and provide the ability to color&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  the cells.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; To test, copy this code to any program name and create screen 100&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  as described in the comments.  After the screen is displayed, hit&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  enter to exit the screen.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Tested in 4.6C and 6.20&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Charles Folwell - cfolwell@csc.com - Feb 2, 2005&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA:&lt;/P&gt;&lt;P&gt;  r_dyn_table      TYPE REF TO data,&lt;/P&gt;&lt;P&gt;  r_wa_dyn_table   TYPE REF TO data,&lt;/P&gt;&lt;P&gt;  r_dock_ctnr      TYPE REF TO cl_gui_docking_container,&lt;/P&gt;&lt;P&gt;  r_alv_grid       TYPE REF TO cl_gui_alv_grid,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  t_fieldcat1      TYPE lvc_t_fcat,           "with cell color&lt;/P&gt;&lt;P&gt;  t_fieldcat2      TYPE lvc_t_fcat,           "without cell color&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  wa_fieldcat      LIKE LINE OF t_fieldcat1,&lt;/P&gt;&lt;P&gt;  wa_cellcolors    TYPE LINE OF lvc_t_scol,&lt;/P&gt;&lt;P&gt;  wa_is_layout     TYPE lvc_s_layo.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FIELD-SYMBOLS:&lt;/P&gt;&lt;P&gt;  &amp;lt;t_dyn_table&amp;gt;    TYPE STANDARD TABLE,&lt;/P&gt;&lt;P&gt;  &amp;lt;wa_dyn_table&amp;gt;   TYPE ANY,&lt;/P&gt;&lt;P&gt;  &amp;lt;t_cellcolors&amp;gt;   TYPE lvc_t_scol,&lt;/P&gt;&lt;P&gt;  &amp;lt;w_field&amp;gt;        TYPE ANY.&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Build field catalog based on your criteria.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  wa_fieldcat-fieldname = 'FIELD1'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-inttype   = 'C'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-outputlen = '10'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-coltext   = 'My Field 1'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-seltext   = wa_fieldcat-coltext.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND wa_fieldcat TO t_fieldcat1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  wa_fieldcat-fieldname = 'FIELD2'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-inttype   = 'C'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-outputlen = '10'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-coltext   = 'My Field 2'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-seltext   = wa_fieldcat-coltext.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND wa_fieldcat TO t_fieldcat1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Before adding cell color table, save fieldcatalog to pass&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; to ALV call.  The ALV call needs a fieldcatalog without&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; the internal table for cell coloring.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  t_fieldcat2[] = t_fieldcat1[].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Add cell color table.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; CALENDAR_TYPE is a structure in the dictionary with a&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  field called COLTAB of type LVC_T_SCOL.  You can use&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  any structure and field that has the type LVC_T_SCOL.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  wa_fieldcat-fieldname = 'T_CELLCOLORS'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-ref_field = 'COLTAB'.&lt;/P&gt;&lt;P&gt;  wa_fieldcat-ref_table = 'CALENDAR_TYPE'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND wa_fieldcat TO t_fieldcat1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Create dynamic table including the internal table&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; for cell coloring.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL METHOD cl_alv_table_create=&amp;gt;create_dynamic_table&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      it_fieldcatalog           = t_fieldcat1&lt;/P&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      ep_table                  = r_dyn_table&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      generate_subpool_dir_full = 1&lt;/P&gt;&lt;P&gt;      OTHERS                    = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;/P&gt;&lt;P&gt;               WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Get access to new table using field symbol.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN r_dyn_table-&amp;gt;* TO &amp;lt;t_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Create work area for new table.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CREATE DATA r_wa_dyn_table LIKE LINE OF &amp;lt;t_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Get access to new work area using field symbol.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN r_wa_dyn_table-&amp;gt;* TO &amp;lt;wa_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Get data into table from somewhere.  Field names are&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; known at this point because field catalog is already&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; built.  Read field names from the field catalog or use&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; COMPONENT &amp;lt;number&amp;gt; in a DO loop to access the fields.  A&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; simpler hard coded approach is used here.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN COMPONENT 'FIELD1' OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;w_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;w_field&amp;gt; = 'ABC'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN COMPONENT 'FIELD2' OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;w_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;w_field&amp;gt; = 'XYZ'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;t_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN COMPONENT 'FIELD1' OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;w_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;w_field&amp;gt; = 'TUV'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN COMPONENT 'FIELD2' OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;w_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;w_field&amp;gt; = 'DEF'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;t_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Color cells based on your criteria.  In this example, a test on&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; FIELD2 is used to decide on color.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  LOOP AT &amp;lt;t_dyn_table&amp;gt; INTO &amp;lt;wa_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    ASSIGN COMPONENT 'FIELD2' OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;w_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Get access to internal table used to color cells.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    ASSIGN COMPONENT 'T_CELLCOLORS'&lt;/P&gt;&lt;P&gt;      OF STRUCTURE &amp;lt;wa_dyn_table&amp;gt; TO &amp;lt;t_cellcolors&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CLEAR wa_cellcolors.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    wa_cellcolors-fname = 'FIELD2'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    IF &amp;lt;w_field&amp;gt; = 'DEF'.&lt;/P&gt;&lt;P&gt;      wa_cellcolors-color-col = '7'.&lt;/P&gt;&lt;P&gt;    ELSE.&lt;/P&gt;&lt;P&gt;      wa_cellcolors-color-col = '5'.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    APPEND wa_cellcolors TO &amp;lt;t_cellcolors&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    MODIFY &amp;lt;t_dyn_table&amp;gt; FROM &amp;lt;wa_dyn_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Display screen.  Define screen 100 as empty, with next screen&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; set to 0 and flow logic of:&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   PROCESS BEFORE OUTPUT.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;     MODULE initialization.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   PROCESS AFTER INPUT.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL SCREEN 100.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; MODULE initialization OUTPUT&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MODULE initialization OUTPUT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Set up for ALV display.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF r_dock_ctnr IS INITIAL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CREATE OBJECT r_dock_ctnr&lt;/P&gt;&lt;P&gt;           EXPORTING&lt;/P&gt;&lt;P&gt;              side  = cl_gui_docking_container=&amp;gt;dock_at_left&lt;/P&gt;&lt;P&gt;              ratio = '90'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CREATE OBJECT r_alv_grid&lt;/P&gt;&lt;P&gt;           EXPORTING i_parent = r_dock_ctnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Set ALV controls for cell coloring table.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    wa_is_layout-ctab_fname = 'T_CELLCOLORS'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Display.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL METHOD r_alv_grid-&amp;gt;set_table_for_first_display&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        is_layout       = wa_is_layout&lt;/P&gt;&lt;P&gt;      CHANGING&lt;/P&gt;&lt;P&gt;        it_outtab       = &amp;lt;t_dyn_table&amp;gt;&lt;/P&gt;&lt;P&gt;        it_fieldcatalog = t_fieldcat2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ELSE.     "grid already prepared&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Refresh display.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL METHOD r_alv_grid-&amp;gt;refresh_table_display&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        i_soft_refresh = ' '&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;        finished       = 1&lt;/P&gt;&lt;P&gt;        OTHERS         = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDMODULE.                 " initialization  OUTPUT&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Apr 2007 11:00:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084357#M432681</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-03T11:00:34Z</dc:date>
    </item>
    <item>
      <title>Re: creating multiple dynamic internal tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084358#M432682</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my question is i have to create multiple fieldcatalog names based on the table names as well multiple dynamic internal table names.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select tabname from dd03L into T_DD03L where tabname in S_TABNAME.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;delete adjacent duplicates from T_DDO3L.&lt;/P&gt;&lt;P&gt;loop at T_DD03l into W_DDO3L&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function REUSE_ALV_FIELDCATALOG_MERGE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_INTERNAL_TABNAME = W_DD03L-TABNAME&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;changing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CT_FIELDCAT  = T_FIELDCAT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*... Create the dynamic internal table&lt;/P&gt;&lt;P&gt;  CALL METHOD cl_alv_table_create=&amp;gt;create_dynamic_table&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      it_fieldcatalog = T_FIELDCAT&lt;/P&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      ep_table        = new_table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now my question is since iam looping through T_DD03L so there will be multiple table names so for every table name there should be different field catalog generated as well as dynamic table generated so how i generate new names for every loop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Apr 2007 11:46:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/creating-multiple-dynamic-internal-tables/m-p/2084358#M432682</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-03T11:46:34Z</dc:date>
    </item>
  </channel>
</rss>

