<?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: Query with Modify statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854919#M361608</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use liek this - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify DBtab from table itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;effects - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mass modify: Inserts new lines or updates existing lines of a database table. The primary keys for identifying the lines to be inserted or updated and the relevant values are taken from the internal table itab. The lines of the internal table itab must satisfy the same conditions as the work area wa in addition 1 to variant 1. &lt;/P&gt;&lt;P&gt;If the internal table itab is empty, SY-SUBRC and SY-DBCNT are set to 0.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 25 Jan 2007 08:50:47 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-01-25T08:50:47Z</dc:date>
    <item>
      <title>Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854918#M361607</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;I want to insert all the records of the table ls_outtab into table gt_outtab  from position 1 onwards , the gt_outtab may or maynot have data,but I can not clear gt_outtab[]. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any way to do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried following but its not working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at ls_outtab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      MODIFY gt_outtab FROM ls_outtab where tabix = sy-tabix .&lt;/P&gt;&lt;P&gt;      endloop.&lt;/P&gt;&lt;P&gt;PLs suggest&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 08:47:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854918#M361607</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T08:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854919#M361608</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use liek this - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify DBtab from table itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;effects - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mass modify: Inserts new lines or updates existing lines of a database table. The primary keys for identifying the lines to be inserted or updated and the relevant values are taken from the internal table itab. The lines of the internal table itab must satisfy the same conditions as the work area wa in addition 1 to variant 1. &lt;/P&gt;&lt;P&gt;If the internal table itab is empty, SY-SUBRC and SY-DBCNT are set to 0.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 08:50:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854919#M361608</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T08:50:47Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854920#M361609</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If both structures are same, you can try this way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND LINES OF ls_outtab TO gt_outtab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the structures are different:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;LOOP AT ls_outtab.
 
  MOVE-CORRESPONDING ls_outtab TO gt_outtab.
  APPEND gt_outtab.

ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards&lt;/P&gt;&lt;P&gt;Eswar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 08:50:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854920#M361609</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T08:50:48Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854921#M361610</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;       MODIFY statement will modify only the existing lines of a table. If you want to insert new lines, then you should try with APPEND statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sharmila&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 08:53:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854921#M361610</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T08:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854922#M361611</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rahul,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If both the tables have the same structure then,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;LOOP AT ITAB1.&lt;/P&gt;&lt;P&gt;MOVE CORRESPONDING ITAB1 to ITAB2.&lt;/P&gt;&lt;P&gt;APPEND ITAB2.&lt;/P&gt;&lt;P&gt;ENDLOOP.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;If ITAB1[] is initial.&lt;/P&gt;&lt;P&gt;Clear: itab2.&lt;/P&gt;&lt;P&gt;refresh itab2.&lt;/P&gt;&lt;P&gt;ENDIF.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vasanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 08:56:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854922#M361611</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T08:56:11Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854923#M361612</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul , &lt;/P&gt;&lt;P&gt; If the structure of both the internal tables are the same user the command&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;INSERT LINES OF ls_outtab   INTO gt_outtab  index 1.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if they are not the same then use loop endloop and use the insert command index 1.&lt;/P&gt;&lt;P&gt;e.g&lt;/P&gt;&lt;P&gt;LOOP AT LS_OUTTAB INTO WA_OUTTAB.&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING WA_OUTTAB TO WA_GT_OUTTAB.&lt;/P&gt;&lt;P&gt;INSERT WA_GT_OUTTAB INTO GT_OUTTAB INDEX 1.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regadrs&lt;/P&gt;&lt;P&gt;Arun&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Assign points if reply is useful&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 09:01:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854923#M361612</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T09:01:40Z</dc:date>
    </item>
    <item>
      <title>Re: Query with Modify statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854924#M361613</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rahul,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try APPEND LINES OF ls_outtab  TO gt_outtab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if found useful...!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;Abhishek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jan 2007 09:18:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/query-with-modify-statement/m-p/1854924#M361613</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-25T09:18:39Z</dc:date>
    </item>
  </channel>
</rss>

