<?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 Re: Internal Tables in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868178#M49353</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sree,&lt;/P&gt;&lt;P&gt;Below you can find a short program in which data from 2 internal tables are downloaded to the presentation server in a loop. Please note that the solution is based on &amp;lt;b&amp;gt;Serdar's answer&amp;lt;/b&amp;gt; and take into consideration this issue when you give points: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: lt_sflight TYPE TABLE OF sflight,&lt;/P&gt;&lt;P&gt;      lt_sbook   TYPE TABLE OF sbook,&lt;/P&gt;&lt;P&gt;      lt_tables  TYPE TABLE OF tablename,&lt;/P&gt;&lt;P&gt;      lv_name    TYPE string,&lt;/P&gt;&lt;P&gt;      lv_file_length TYPE i,&lt;/P&gt;&lt;P&gt;      lv_file_name   TYPE string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FIELD-SYMBOLS: &amp;lt;fs_table&amp;gt; TYPE STANDARD TABLE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*fill an internal table which holds names of your *internal tables&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND 'LT_SBOOK'     TO lt_tables.&lt;/P&gt;&lt;P&gt;APPEND 'LT_SFLIGHT'   TO lt_tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*data selection&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM sflight&lt;/P&gt;&lt;P&gt;         INTO TABLE lt_sflight&lt;/P&gt;&lt;P&gt;         WHERE carrid = 'LH'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT *&lt;/P&gt;&lt;P&gt;      FROM sbook UP TO 20 ROWS&lt;/P&gt;&lt;P&gt;      INTO TABLE lt_sbook.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT lt_tables INTO lv_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CONCATENATE 'C:\'&lt;/P&gt;&lt;P&gt;              lv_name&lt;/P&gt;&lt;P&gt;              '.txt'&lt;/P&gt;&lt;P&gt;              INTO lv_file_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN (lv_name) TO &amp;lt;fs_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'GUI_DOWNLOAD'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      filename                = lv_file_name&lt;/P&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      filelength              = lv_file_length&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      data_tab                = &amp;lt;fs_table&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 03 Jan 2005 19:51:45 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-01-03T19:51:45Z</dc:date>
    <item>
      <title>Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868175#M49350</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;My problem is.&lt;/P&gt;&lt;P&gt;I have 5 internal tables with different structure and different data. and to download this data i used the function module module WS_UPLOAD, in this function module i have to pass the internal table. Now my problem is, how to pass internal table to this function module dynamically, in order to avoid the number of lines of code.&lt;/P&gt;&lt;P&gt;Thanks and regards&lt;/P&gt;&lt;P&gt;sree&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jan 2005 16:16:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868175#M49350</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-03T16:16:56Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868176#M49351</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi sree,&lt;/P&gt;&lt;P&gt;  probably the FM you use to download is the &amp;lt;b&amp;gt;WS_DOWNLOAD&amp;lt;/b&amp;gt;... in any case, try using a field-symbol.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;Stefano&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jan 2005 16:49:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868176#M49351</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-03T16:49:06Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868177#M49352</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sree&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As suggested by Stefano, you can use field symbols. Secondly, use the FM &amp;lt;b&amp;gt;"GUI_UPLOAD"&amp;lt;/b&amp;gt; instead of &amp;lt;b&amp;gt;"WS_UPLOAD"&amp;lt;/b&amp;gt; since the latter one is obsolete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;u&amp;gt;&amp;lt;b&amp;gt;e.g.&amp;lt;/b&amp;gt;&amp;lt;/u&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA lv_tabname(30) TYPE c .
FIELD-SYMBOLS &amp;lt;b&amp;gt;&amp;lt;f&amp;gt;&amp;lt;/b&amp;gt; TYPE TABLE .

CASE &amp;lt;i&amp;gt;&amp;lt;case&amp;gt;&amp;lt;/i&amp;gt; .
  WHEN &amp;lt;i&amp;gt;&amp;lt;case_1&amp;gt;&amp;lt;/i&amp;gt; .
   lv_tabname = &amp;lt;i&amp;gt;&amp;lt;name_of_itab_1&amp;gt;&amp;lt;/i&amp;gt; .
  WHEN &amp;lt;i&amp;gt;&amp;lt;case_2&amp;gt;&amp;lt;/i&amp;gt; .
   lv_tabname = &amp;lt;i&amp;gt;&amp;lt;name_of_itab_2&amp;gt;&amp;lt;/i&amp;gt; .
  ...
  WHEN &amp;lt;i&amp;gt;&amp;lt;case_5&amp;gt;&amp;lt;/i&amp;gt; .
   lv_tabname = &amp;lt;i&amp;gt;&amp;lt;name_of_itab_5&amp;gt;&amp;lt;/i&amp;gt; .
ENDCASE .

...

ASSIGN (lv_tabname) TO &amp;lt;b&amp;gt;&amp;lt;f&amp;gt;&amp;lt;/b&amp;gt; .
IF sy-subrc NE 0 .
*--Handle Error
ENDIF .

CALL FUNCTION &amp;lt;b&amp;gt;'GUI_UPLOAD'&amp;lt;/b&amp;gt;
  ...
  TABLES
    itab = &amp;lt;b&amp;gt;&amp;lt;f&amp;gt;&amp;lt;/b&amp;gt; 
...
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*--Serdar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jan 2005 17:00:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868177#M49352</guid>
      <dc:creator>ssimsekler</dc:creator>
      <dc:date>2005-01-03T17:00:00Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868178#M49353</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sree,&lt;/P&gt;&lt;P&gt;Below you can find a short program in which data from 2 internal tables are downloaded to the presentation server in a loop. Please note that the solution is based on &amp;lt;b&amp;gt;Serdar's answer&amp;lt;/b&amp;gt; and take into consideration this issue when you give points: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: lt_sflight TYPE TABLE OF sflight,&lt;/P&gt;&lt;P&gt;      lt_sbook   TYPE TABLE OF sbook,&lt;/P&gt;&lt;P&gt;      lt_tables  TYPE TABLE OF tablename,&lt;/P&gt;&lt;P&gt;      lv_name    TYPE string,&lt;/P&gt;&lt;P&gt;      lv_file_length TYPE i,&lt;/P&gt;&lt;P&gt;      lv_file_name   TYPE string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FIELD-SYMBOLS: &amp;lt;fs_table&amp;gt; TYPE STANDARD TABLE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*fill an internal table which holds names of your *internal tables&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND 'LT_SBOOK'     TO lt_tables.&lt;/P&gt;&lt;P&gt;APPEND 'LT_SFLIGHT'   TO lt_tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*data selection&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM sflight&lt;/P&gt;&lt;P&gt;         INTO TABLE lt_sflight&lt;/P&gt;&lt;P&gt;         WHERE carrid = 'LH'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT *&lt;/P&gt;&lt;P&gt;      FROM sbook UP TO 20 ROWS&lt;/P&gt;&lt;P&gt;      INTO TABLE lt_sbook.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT lt_tables INTO lv_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CONCATENATE 'C:\'&lt;/P&gt;&lt;P&gt;              lv_name&lt;/P&gt;&lt;P&gt;              '.txt'&lt;/P&gt;&lt;P&gt;              INTO lv_file_name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN (lv_name) TO &amp;lt;fs_table&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'GUI_DOWNLOAD'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      filename                = lv_file_name&lt;/P&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;P&gt;      filelength              = lv_file_length&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      data_tab                = &amp;lt;fs_table&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jan 2005 19:51:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868178#M49353</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-03T19:51:45Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868179#M49354</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt; To download data from Internal table to presentation server make use of the funcion ws_download where in function wud ask for the internal table.secondly for dynamically selecting the table u shud define a field symbol and based on the user selection u shud assign the internal table to the field symbol and same has to be passed on to the function called ws_download.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;suresh krishnan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jan 2005 02:56:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868179#M49354</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-04T02:56:38Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868180#M49355</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Thank u very much for your help.&lt;/P&gt;&lt;P&gt;I implemented ur technique.&lt;/P&gt;&lt;P&gt;the sample code is&lt;/P&gt;&lt;P&gt;DATA lv_tabnamE(30) TYPE C.&lt;/P&gt;&lt;P&gt;  FIELD-SYMBOLS &amp;lt;FS&amp;gt; TYPE STANDARD TABLE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CASE sy-dynnr .&lt;/P&gt;&lt;P&gt;    WHEN '0110'.&lt;/P&gt;&lt;P&gt;      lv_tabname = TBL_MAtSTR.&lt;/P&gt;&lt;P&gt;    WHEN '0120'.&lt;/P&gt;&lt;P&gt;      lv_tabname = TBL_MATHAND.&lt;/P&gt;&lt;P&gt;    WHEN '0130'.&lt;/P&gt;&lt;P&gt;      lv_tabname = TBL_PCDEL.&lt;/P&gt;&lt;P&gt;    WHEN '0140'.&lt;/P&gt;&lt;P&gt;      lv_tabname = TBL_INLOG.&lt;/P&gt;&lt;P&gt;    WHEN '0150'.&lt;/P&gt;&lt;P&gt;      lv_tabname =  TBL_PKNG.&lt;/P&gt;&lt;P&gt;  ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN (lv_tabname) TO &amp;lt;FS&amp;gt;.&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'WS_DOWNLOAD'&lt;/P&gt;&lt;P&gt;     EXPORTING&lt;/P&gt;&lt;P&gt;       FILENAME                      = P_P_FILE1&lt;/P&gt;&lt;P&gt;       FILETYPE                      = 'DAT'&lt;/P&gt;&lt;P&gt;      TABLES&lt;/P&gt;&lt;P&gt;        DATA_TAB                      = &amp;lt;FS&amp;gt;&lt;/P&gt;&lt;P&gt;    IF SY-SUBRC &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When i executed, i got the dump.&lt;/P&gt;&lt;P&gt;its stated &lt;/P&gt;&lt;P&gt;Error analysis                                                                                &lt;/P&gt;&lt;P&gt;You attempted to access an unassigned field symbol                              &lt;/P&gt;&lt;P&gt;(data segment 32770).                                                                                &lt;/P&gt;&lt;P&gt;This error occurs:                                                              &lt;/P&gt;&lt;P&gt;- if you address a typed field symbol before it has been set with               &lt;/P&gt;&lt;P&gt;  ASSIGN or                                                                     &lt;/P&gt;&lt;P&gt;- if you address a field symbol that has been reset with UNASSIGN               &lt;/P&gt;&lt;P&gt;  or pointed to a local field that no longer exists, or                         &lt;/P&gt;&lt;P&gt;- if you address a field symbol that pointed to a line of an internal           &lt;/P&gt;&lt;P&gt;  table that has now been deleted, or                                           &lt;/P&gt;&lt;P&gt;- if you address a global function interface partameter, even                   &lt;/P&gt;&lt;P&gt;  though the relevant function module is not active,                            &lt;/P&gt;&lt;P&gt;  i.e. it is not in the list of active calls. You can get the list              &lt;/P&gt;&lt;P&gt;  of active calls from the this short dump.                                     &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plz kindly help me in this regard&lt;/P&gt;&lt;P&gt;sree&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jan 2005 15:01:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868180#M49355</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-04T15:01:51Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868181#M49356</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;According to the dump you have failed to assign the internal table. To find out what happened you should debug the asssing statement and check the contents of lv_tabname. Make sure that it contains the variablename of the internal table in capital letters.&lt;/P&gt;&lt;P&gt;Since there are no apostrophes around TBL_MASTER (and the others) , I assume that TBL_MASTER holds the name of the internal table. If it is the internal table, use 'TBL_MASTER'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW to avoid dumps make sure to check sy-subrc = 0 after the assign statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Christian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jan 2005 15:22:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868181#M49356</guid>
      <dc:creator>ChristianFi</dc:creator>
      <dc:date>2005-01-04T15:22:31Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868182#M49357</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sree,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Change your code as follows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  DATA lv_tabname(30) TYPE c.
  FIELD-SYMBOLS &amp;lt;fs&amp;gt; TYPE STANDARD TABLE.

  CASE sy-dynnr .
    WHEN '0110'.
      lv_tabname = 'TBL_MATSTR'.
    WHEN '0120'.
      lv_tabname = 'TBL_MATHAND'.
    WHEN '0130'.
      lv_tabname = 'TBL_PCDEL'.
    WHEN '0140'.
      lv_tabname = 'TBL_INLOG'.
    WHEN '0150'.
      lv_tabname = 'TBL_PKNG'.
  ENDCASE.

  ASSIGN (lv_tabname) TO &amp;lt;fs&amp;gt;.
  IF sy-subrc = 0.
    CALL FUNCTION 'WS_DOWNLOAD'
         EXPORTING
              filename = p_p_file1
              filetype = 'DAT'
         TABLES
              data_tab = &amp;lt;fs&amp;gt;.
    IF sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
  ELSE.
*-- Problem with assignment
  ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let us know if it solved your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jan 2005 15:53:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868182#M49357</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-04T15:53:18Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868183#M49358</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi frinds,Problem again.&lt;/P&gt;&lt;P&gt;sanmple code&lt;/P&gt;&lt;P&gt;FORM download_file USING    P_P_FILE1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DATA lv_tabnamE(30) TYPE C.&lt;/P&gt;&lt;P&gt;  FIELD-SYMBOLS &amp;lt;FS&amp;gt; TYPE STANDARD TABLE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CASE sy-dynnr .&lt;/P&gt;&lt;P&gt;    WHEN '0110'.&lt;/P&gt;&lt;P&gt;      lv_tabname = 'TBL_MAtSTR'.&lt;/P&gt;&lt;P&gt;    WHEN '0120'.&lt;/P&gt;&lt;P&gt;      lv_tabname = 'TBL_MATHAND'.&lt;/P&gt;&lt;P&gt;    WHEN '0130'.&lt;/P&gt;&lt;P&gt;      lv_tabname = 'TBL_PCDEL'.&lt;/P&gt;&lt;P&gt;    WHEN '0140'.&lt;/P&gt;&lt;P&gt;      lv_tabname = 'TBL_INLOG'.&lt;/P&gt;&lt;P&gt;    WHEN '0150'.&lt;/P&gt;&lt;P&gt;      lv_tabname =  'TBL_PKNG'.&lt;/P&gt;&lt;P&gt;  ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN (lv_tabname) TO &amp;lt;FS&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'WS_DOWNLOAD'&lt;/P&gt;&lt;P&gt;     EXPORTING&lt;/P&gt;&lt;P&gt;       FILENAME                      = P_P_FILE1&lt;/P&gt;&lt;P&gt;       FILETYPE                      = 'DAT'&lt;/P&gt;&lt;P&gt;      TABLES&lt;/P&gt;&lt;P&gt;        DATA_TAB                      = &amp;lt;FS&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt; Message E000(0) with 'not assigned'.&lt;/P&gt;&lt;P&gt; ENDIF.&lt;/P&gt;&lt;P&gt; ENDFORM.                    " download_file&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please do help me solve this &lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;sree&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2005 14:38:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868183#M49358</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-05T14:38:12Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868184#M49359</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I can imagine that the lover case t in 'TBL_MAtSTR' gives problems.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ferdi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2005 15:18:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868184#M49359</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-05T15:18:07Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868185#M49360</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;No problem with the case as i did not used that options..&lt;/P&gt;&lt;P&gt;i was checking with screen no 140 only.&lt;/P&gt;&lt;P&gt;plz help me&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;sree&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jan 2005 07:49:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868185#M49360</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-06T07:49:59Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868186#M49361</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Does it still dump, or does it run into your error message&lt;/P&gt;&lt;P&gt;What is the value of lv_tabname? &lt;/P&gt;&lt;P&gt;Can you show us the part where you have declared the internal table?&lt;/P&gt;&lt;P&gt;Does your internal table have a header? in this case you have to assign ('TAB_MATSTR[]') to the field symbol (in this case the brackets indicate that you were referring to the body not the header. &lt;/P&gt;&lt;P&gt;Christian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jan 2005 10:52:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868186#M49361</guid>
      <dc:creator>ChristianFi</dc:creator>
      <dc:date>2005-01-06T10:52:26Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868187#M49362</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sree,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry I missed the key part(as Christian pointed out) in the code mentioned in my response. Change your code as follows and it should work.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA lv_tabname(30) TYPE c.
  FIELD-SYMBOLS &amp;lt;fs&amp;gt; TYPE STANDARD TABLE.
 
  CASE sy-dynnr .
    WHEN '0110'.
      lv_tabname = 'TBL_MATSTR[]'.
    WHEN '0120'.
      lv_tabname = 'TBL_MATHAND[]'.
    WHEN '0130'.
      lv_tabname = 'TBL_PCDEL[]'.
    WHEN '0140'.
      lv_tabname = 'TBL_INLOG[]'.
    WHEN '0150'.
      lv_tabname = 'TBL_PKNG[]'.
  ENDCASE.
 
  ASSIGN (lv_tabname) TO &amp;lt;fs&amp;gt;.
  IF sy-subrc = 0.
    CALL FUNCTION 'WS_DOWNLOAD'
         EXPORTING
              filename = p_p_file1
              filetype = 'DAT'
         TABLES
              data_tab = &amp;lt;fs&amp;gt;.
    IF sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
  ELSE.
*-- Problem with assignment
  ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let us know if it solved your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jan 2005 15:20:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables/m-p/868187#M49362</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-01-06T15:20:15Z</dc:date>
    </item>
  </channel>
</rss>

