<?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: Update and Modify in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130590#M111566</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Saurabh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To insert lines into a database table regardless of whether there is already a line in the table with&lt;/P&gt;&lt;P&gt;the same primary key .. we use MODIFY..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the database already contains a line with the same primary key as the line to be inserted,&lt;/P&gt;&lt;P&gt;MODIFY works like UPDATE, that is, the line is changed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For performance reasons, you should use MODIFY only if you cannot distinguish between these&lt;/P&gt;&lt;P&gt;two options in your ABAP program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;satesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 24 Feb 2006 04:12:08 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-02-24T04:12:08Z</dc:date>
    <item>
      <title>Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130584#M111560</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;   What is the difference betwenn "update DB table" and " Modify DB table"?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plz reply&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Saurabh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:04:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130584#M111560</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:04:33Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130585#M111561</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Update DB table:&lt;/P&gt;&lt;P&gt;Inserts new entries if not available or changes the content.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify:&lt;/P&gt;&lt;P&gt;Changes the existing table rows.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:07:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130585#M111561</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:07:39Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130586#M111562</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Update database table command will insert a new entry. But MODIFY will check if record already exist, if it exist then it will modify existing record else it will insert new record in db table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For more details here is screenshot from F1 help -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INSERT - Inserting Data in Database Tables                                                                                &lt;/P&gt;&lt;P&gt;Variants:                                                        &lt;/P&gt;&lt;P&gt;              1. INSERT INTO dbtab [CLIENT SPECIFIED] VALUES wa.               &lt;/P&gt;&lt;P&gt;                 INSERT INTO (dbtabname) [CLIENT SPECIFIED] VALUES wa.         &lt;/P&gt;&lt;P&gt;              2. INSERT dbtab [CLIENT SPECIFIED] FROM TABLE itab. oder         &lt;/P&gt;&lt;P&gt;                 INSERT (dbtabname) [CLIENT SPECIFIED] FROM TABLE itab.        &lt;/P&gt;&lt;P&gt;              3. INSERT dbtab [CLIENT SPECIFIED]. oder                         &lt;/P&gt;&lt;P&gt;                 INSERT *dbtab [CLIENT SPECIFIED]. oder                        &lt;/P&gt;&lt;P&gt;                 INSERT (dbtabname) [CLIENT SPECIFIED] ... .                                                                                &lt;/P&gt;&lt;P&gt;Effect        Adds new records to a database table (see relational             &lt;/P&gt;&lt;P&gt;              database). You can specify the name of the database table        &lt;/P&gt;&lt;P&gt;              either directly in the program in the form dbtab or at runtime   &lt;/P&gt;&lt;P&gt;              as the contents of the field dbtabname. In either case, the      &lt;/P&gt;&lt;P&gt;              database table must be declared in the ABAP Dictionary. You      &lt;/P&gt;&lt;P&gt;              can only insert data using a view if the view refers to a        &lt;/P&gt;&lt;P&gt;              single table and has the maintenance status "No restriction"     &lt;/P&gt;&lt;P&gt;              in the ABAP Dictionary.                                                                                &lt;/P&gt;&lt;P&gt;By default, data is only inserted in the current client.         &lt;/P&gt;&lt;P&gt;              However, if you use the CLIENT SPECIFIED addition, you can       &lt;/P&gt;&lt;P&gt;              switch off the automatic client handling. This enables you to    &lt;/P&gt;&lt;P&gt;              enter data for any client in a cross-client table, not just in   &lt;/P&gt;&lt;P&gt;              the client in which you are logged on. In this case, the         &lt;/P&gt;&lt;P&gt;              client field is treated like a normal field to which you can     &lt;/P&gt;&lt;P&gt;              assign a value in the work area.                                                                                &lt;/P&gt;&lt;P&gt;MODIFY - Change a database table                                                                                &lt;/P&gt;&lt;P&gt;Variants:                                                                                &lt;/P&gt;&lt;P&gt;1. MODIFY dbtab. or                                                      &lt;/P&gt;&lt;P&gt;                  MODIFY *dbtab. or                                                     &lt;/P&gt;&lt;P&gt;                  MODIFY (dbtabname) ... ..                                             &lt;/P&gt;&lt;P&gt;               2. MODIFY dbtab FROM TABLE itab. or                                      &lt;/P&gt;&lt;P&gt;                  MODIFY (dbtabname) FROM TABLE itab.                                   &lt;/P&gt;&lt;P&gt;               3. MODIFY dbtab VERSION vers. or                                         &lt;/P&gt;&lt;P&gt;                  MODIFY *dbtab VERSION vers.                                                                                &lt;/P&gt;&lt;P&gt;Effect        Inserts new lines or updates existing lines in a database                &lt;/P&gt;&lt;P&gt;               table (s. relational database). If a line with the specified             &lt;/P&gt;&lt;P&gt;               primary key already exists, an UPDATE is executed. Otherwise,            &lt;/P&gt;&lt;P&gt;               an INSERT is performed. You can specify the name of the                  &lt;/P&gt;&lt;P&gt;               database table either in the program itself in the form MODIFY           &lt;/P&gt;&lt;P&gt;               dbtab ... or at runtime as the contents of the field dbtabname           &lt;/P&gt;&lt;P&gt;               in the form MODIFY (dbtabname) ... . In both cases, the                  &lt;/P&gt;&lt;P&gt;               database table must be defined in the ABAP Dictionary.                   &lt;/P&gt;&lt;P&gt;               Normally, records are inserted or updated only in the current            &lt;/P&gt;&lt;P&gt;               client. Data can only be inserted or updated using a view, if            &lt;/P&gt;&lt;P&gt;               the view refers to a single table and was created in the ABAP            &lt;/P&gt;&lt;P&gt;               Dictionary with the maintenance status "No restriction".                                                                                &lt;/P&gt;&lt;P&gt;MODIFY belongs to the Open SQL command set.                                                                                &lt;/P&gt;&lt;P&gt;When the statement has been executed, the system field                   &lt;/P&gt;&lt;P&gt;               SY-DBCNT contains the number of edited lines.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:09:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130586#M111562</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:09:51Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130587#M111563</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wenceslaus,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am sorry but you got it reversed. Update updates the existing records in the database and if a record does not exist, it will fail.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify on the other hand will insert the records if the records with the same key does not exist and updates if they exist.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:10:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130587#M111563</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:10:44Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130588#M111564</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:&lt;/P&gt;&lt;P&gt;If the value of key fields in the internal table matches with the key fields values in database table,modify will update the existing entry.Otherwise,it will insert new entry.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Update:&lt;/P&gt;&lt;P&gt;To update db table,it is mandatory that the value of key fields in internal table should match with database table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly reward points by clikcing the star on the left of reply,if it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:10:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130588#M111564</guid>
      <dc:creator>jayanthi_jayaraman</dc:creator>
      <dc:date>2006-02-24T04:10:55Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130589#M111565</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Update will not insert new records if the records are not there.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:11:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130589#M111565</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:11:43Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130590#M111566</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Saurabh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To insert lines into a database table regardless of whether there is already a line in the table with&lt;/P&gt;&lt;P&gt;the same primary key .. we use MODIFY..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the database already contains a line with the same primary key as the line to be inserted,&lt;/P&gt;&lt;P&gt;MODIFY works like UPDATE, that is, the line is changed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For performance reasons, you should use MODIFY only if you cannot distinguish between these&lt;/P&gt;&lt;P&gt;two options in your ABAP program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;satesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:12:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130590#M111566</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:12:08Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130591#M111567</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Srinivas,&lt;/P&gt;&lt;P&gt;Yes. You are right.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Update DB table:&lt;/P&gt;&lt;P&gt;Changes the existing table rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify:&lt;/P&gt;&lt;P&gt;Inserts new entries if not available or changes the content.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:14:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130591#M111567</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:14:20Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130592#M111568</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Somewhat different syntax. Simply do F1 on each and you'll see the differences.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:16:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130592#M111568</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:16:13Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130593#M111569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Update is generally used for changing rows in database tables&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;update vbak set cmgst = 'C' where kunnr = '999999999'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modify generally relates to internal table changes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab into wa.&lt;/P&gt;&lt;P&gt; wa-myField = 'X'.&lt;/P&gt;&lt;P&gt; modify table itab from wa.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:16:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130593#M111569</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:16:21Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130594#M111570</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;    &amp;lt;u&amp;gt;MODIFY&amp;lt;/u&amp;gt; TO INSERT LINES INTO DATABSE TABLE REGARDLESS OF WHETHER THE PRIMARY KEY OF THIS LINE IS ALREADY EXISTS, USE MODIFY STATEMENTS. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    IF THE DATABASE TABLE CONTAINS NO LINE WITH SAME PRIMARY KEY AS THE LINE TO BE INSERTED, MODIFY words LIKE &amp;lt;u&amp;gt;INSERT&amp;lt;/u&amp;gt; IS USED.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    IF THE DATABASE TABLE ALREADY CONTAINS LINE WITH SAME PRIMARY KEY AS THE LINE TO BE INSERTED,MODIFY words LIKE  &amp;lt;u&amp;gt;UPDATE&amp;lt;/u&amp;gt; ie THE LINE IS CHANGED&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FOR MORE DOCUMENTATION GO THROUGH&lt;/P&gt;&lt;P&gt;&amp;lt;a href="http://www.sappoint.com/faq/faqsql.pdf"&amp;gt;http://www.sappoint.com/faq/faqsql.pdf&amp;lt;/a&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF IT FINDS USEFUL PLEASE REWARD POINTS&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REGARDS&lt;/P&gt;&lt;P&gt;ANOOP&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Feb 2006 04:19:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130594#M111570</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-02-24T04:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: Update and Modify</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130595#M111571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;tx&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Jul 2011 09:35:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-and-modify/m-p/1130595#M111571</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-07-28T09:35:23Z</dc:date>
    </item>
  </channel>
</rss>

