<?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 problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193599#M1002412</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;Read table itab into wa_tab with key cusno = 9.

If sy-subrc eq 0.
wa_tab-cusno = 0.
modify ifab from wa_tab index sy-tabix.
Endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 24 Jul 2008 06:39:03 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-07-24T06:39:03Z</dc:date>
    <item>
      <title>Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193592#M1002405</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know that there is a way of modifying a record in an internal table while looping. But is it possible to modify a record in itable without a loop? And only one field should only be modified. I want to modify a record in itab. I want to modify the customer number in itab, where the customer number is 9.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In sql it is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;update table set cusno = 0 where cusno = 9.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible in an internal table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 05:55:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193592#M1002405</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T05:55:52Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193593#M1002406</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;  You can use the modify statement after the read statement for your requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  read table itab where field = 9.&lt;/P&gt;&lt;P&gt;  if sy-subrc eq 0.&lt;/P&gt;&lt;P&gt;    modify itab transporting field.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Veeresh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 05:58:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193593#M1002406</guid>
      <dc:creator>former_member673464</dc:creator>
      <dc:date>2008-07-24T05:58:49Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193594#M1002407</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;STRONG&gt;Katrina Dy&lt;/STRONG&gt;,&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Write read statement first and then write update sytax.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Read table itab  into fs_tab with key cusno = 9.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc eq 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;itab-cusno = 0.&lt;/P&gt;&lt;P&gt;modify  ifab from fs_tab.&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;&lt;STRONG&gt;Mahi&lt;/STRONG&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 05:59:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193594#M1002407</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T05:59:41Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193595#M1002408</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try this way:&lt;/P&gt;&lt;P&gt;1. Read table (itab) into wa_itab with key customer = xxx.&lt;/P&gt;&lt;P&gt;2. If sy-subrc = 0, get sy-tabix (index of that record).&lt;/P&gt;&lt;P&gt;3. set the changes that you want to make in wa_itab.&lt;/P&gt;&lt;P&gt;4. Modify (itab) index sy-tabix from wa_itab.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:03:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193595#M1002408</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:03:51Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193596#M1002409</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;A href="http://help.sap.com/saphelp_nw04/helpdata/en/d3/2e974d35c511d1829f0000e829fbfe/frameset.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04/helpdata/en/d3/2e974d35c511d1829f0000e829fbfe/frameset.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Jagadeesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:04:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193596#M1002409</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:04:06Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193597#M1002410</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Katrina, &lt;/P&gt;&lt;P&gt; Try to use index for modifying internal table.To modify the internal table without loop can be done through READ Statement where you can use your key fields and get the record and also index value and hence modify the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Sudharshan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:08:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193597#M1002410</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:08:32Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193598#M1002411</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hey &lt;/P&gt;&lt;P&gt;am not very clear but i can send you the sample code.&lt;/P&gt;&lt;P&gt;Just refer to this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT carrid&lt;/P&gt;&lt;P&gt;              connid&lt;/P&gt;&lt;P&gt;              price&lt;/P&gt;&lt;P&gt;       FROM sflight&lt;/P&gt;&lt;P&gt;       UP TO 10 ROWS&lt;/P&gt;&lt;P&gt;       INTO TABLE itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE itab INDEX 1.&lt;/P&gt;&lt;P&gt;itab-price = itab-price - 10.&lt;/P&gt;&lt;P&gt;MODIFY itab INDEX 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;Incase you dont know the index , just store the sy-tabix value into another variable say v_tabix and then modify it. The sy-tabix value must be stored immediately after you write the read statement.&lt;/P&gt;&lt;P&gt;I dont know any other way&lt;/P&gt;&lt;P&gt;hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt; Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:11:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193598#M1002411</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:11:10Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193599#M1002412</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;Read table itab into wa_tab with key cusno = 9.

If sy-subrc eq 0.
wa_tab-cusno = 0.
modify ifab from wa_tab index sy-tabix.
Endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:39:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193599#M1002412</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:39:03Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193600#M1002413</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you don't use BINARY SEARCH or a sorted table, then you can also make the full loop, there is nt much difference.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And it is usually not posible to use READ with index because the index is not known.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But you should keep the index after the READ and do the MODIY with index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Siegfried&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:48:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193600#M1002413</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:48:30Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193601#M1002414</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello,&lt;/P&gt;&lt;P&gt;  one good way is to read that record with key values and then write a modify stmt transporting the value to be modified with where cause.......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;int_tab &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;F1     F2     F3&lt;/P&gt;&lt;P&gt;A       C        5&lt;/P&gt;&lt;P&gt;B       E        3&lt;/P&gt;&lt;P&gt;D       F        1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so  now if u want to modify F3 field from int_tab with value 22 where F1 = B and F2 = E&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then&lt;/P&gt;&lt;P&gt;read table int_tab with key F1 = B &lt;/P&gt;&lt;P&gt;                                       F2 = E.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;int_tab-F3 = 22.&lt;/P&gt;&lt;P&gt;modify int_tab trnsporting F3 where F1 = B &lt;/P&gt;&lt;P&gt;                                           and    F2 = E.&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;Mark the post answered once ur problem is solved .... &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2008 06:56:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/4193601#M1002414</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-24T06:56:01Z</dc:date>
    </item>
  </channel>
</rss>

