<?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 Table Field as a Parameter in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518389#M1424748</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Sandy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Field symbols, this can be achieved very easily &lt;SPAN __jive_emoticon_name="wink"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: 
TEMP TYPE N,
FNAME TYPE CHAR3.

FIELD-SYMBOLS: &amp;lt;FVAL&amp;gt; TYPE ANY.

CONCATENATE 'W' TEMP INTO FNAME. CONDENSE FNAME NO-GAPS.

ASSIGN COMPONENT FNAME OF STRUCTURE ITAB INTO &amp;lt;FVAL&amp;gt;.
IF SY-SUBRC = 0.
&amp;lt;FVAL&amp;gt; = 1.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope i am clear.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Suhas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Jan 2010 10:20:22 GMT</pubDate>
    <dc:creator>SuhaSaha</dc:creator>
    <dc:date>2010-01-06T10:20:22Z</dc:date>
    <item>
      <title>Internal Table Field as a Parameter</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518388#M1424747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;         I have a internal table as shown below.&lt;/P&gt;&lt;P&gt;       Data : Begin of itab occurs 0,&lt;/P&gt;&lt;P&gt;                 w1 type i&lt;/P&gt;&lt;P&gt;                 w2 type i,&lt;/P&gt;&lt;P&gt;                 w3 type i,&lt;/P&gt;&lt;P&gt;                 w4 type i,&lt;/P&gt;&lt;P&gt;               end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     data : temp type i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My query is I want to assign a numeric to the  fields in ITAB depending upon the value of temp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If temp = 1&lt;/P&gt;&lt;P&gt;   itab-w1 = 1.&lt;/P&gt;&lt;P&gt;elseif temp = 2&lt;/P&gt;&lt;P&gt;  itab-w2 = 1&lt;/P&gt;&lt;P&gt;elseif temp = 3&lt;/P&gt;&lt;P&gt; itab-w3 = 1.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have 72 fields like this.&lt;/P&gt;&lt;P&gt;I want to concatenate a 'W' &amp;amp;  temp into a character and pass this as parameter to Internal Table field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let me know if the above scenario is possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you all in advance&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jan 2010 10:12:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518388#M1424747</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-06T10:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Table Field as a Parameter</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518389#M1424748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Sandy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Field symbols, this can be achieved very easily &lt;SPAN __jive_emoticon_name="wink"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: 
TEMP TYPE N,
FNAME TYPE CHAR3.

FIELD-SYMBOLS: &amp;lt;FVAL&amp;gt; TYPE ANY.

CONCATENATE 'W' TEMP INTO FNAME. CONDENSE FNAME NO-GAPS.

ASSIGN COMPONENT FNAME OF STRUCTURE ITAB INTO &amp;lt;FVAL&amp;gt;.
IF SY-SUBRC = 0.
&amp;lt;FVAL&amp;gt; = 1.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope i am clear.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Suhas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jan 2010 10:20:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518389#M1424748</guid>
      <dc:creator>SuhaSaha</dc:creator>
      <dc:date>2010-01-06T10:20:22Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Table Field as a Parameter</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518390#M1424749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yes you can...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Initially the value of temp will be 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now if you are increasing the value of temp (counter increament )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check for temp value before assigning as you did &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ie :&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt; If temp = 1&lt;/P&gt;&lt;P&gt;itab-w1 = 1.&lt;/P&gt;&lt;P&gt;elseif temp = 2&lt;/P&gt;&lt;P&gt;itab-w2 = 1&lt;/P&gt;&lt;P&gt;elseif temp = 3&lt;/P&gt;&lt;P&gt;itab-w3 = 1.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Satish Boguda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jan 2010 10:23:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-field-as-a-parameter/m-p/6518390#M1424749</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-06T10:23:45Z</dc:date>
    </item>
  </channel>
</rss>

