<?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 query in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550385#M249744</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi KPR,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't think so...you can double check in the book.&lt;/P&gt;&lt;P&gt;Please award useful replies and close the thread if it is answered.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Sep 2006 19:09:22 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-09-07T19:09:22Z</dc:date>
    <item>
      <title>Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550378#M249737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi guys, &lt;/P&gt;&lt;P&gt;plz let me know if "UPDATE" statment works like "INSERT" at any point if there is no matching key fields in the "UPDATE" statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If yes. plz give me the exact syntax, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is simple I guess. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thx,&lt;/P&gt;&lt;P&gt;Ramesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 17:53:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550378#M249737</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T17:53:17Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550379#M249738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hai Kpr,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variants&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. UPDATE dbtab SET s1 ... sn. &lt;/P&gt;&lt;P&gt;2. UPDATE dbtab. or &lt;/P&gt;&lt;P&gt;UPDATE *dbtab. or &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) ... . &lt;/P&gt;&lt;P&gt;3. UPDATE dbtab FROM TABLE itab. or &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) FROM TABLE itab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Updates values in a database table (see Relational database ). You can specify the name of the database table either directly in the form dbtab or at runtime as contents of the field dbtabname . In both cases, the table must be known to the ABAP/4 Dictionary . If you specify the name of the database table directly, the program must also contain an appropriate TABLES statement. Normally, lines are updated only in the current client. Data can only be updated using a view if the view refers to a single table and was created in the ABAP/4 Dictionary with the maintenance status "No restriction". &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE belongs to the Open SQL command set. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Notes&lt;/P&gt;&lt;P&gt;Authorization checks are not supported by the UPDATE statement. You must include these in the program yourself. &lt;/P&gt;&lt;P&gt;Changes to lines made with the UPDATE command only become final after a database commit (see LUW ). Prior to this, any database update can be canceled by a database rollback (see Programming transactions ). &lt;/P&gt;&lt;P&gt;In the dialog system, you cannot rely on the database system locking mechanism alone to synchronize simultaneous access to the same database by several users. Therefore, it is often necessary to use the SAP locking mechanism . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variant 1&lt;/P&gt;&lt;P&gt;UPDATE dbtab SET s1 ... sn. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Additions&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. ... WHERE condition &lt;/P&gt;&lt;P&gt;2. ... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Updates values in a database table. If there is no WHERE clause , all lines (in the current client) are updated. If a WHERE condition is specified, only those records which satisfy the condition are updated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The SET clause s1 ... sn identifies the columns to be updated and assigns values to them. Three types of SET statements si are supported: &lt;/P&gt;&lt;P&gt;f = g In all selected lines, the database table column determined by f receives the values of the ABAP/4 field or literal g . &lt;/P&gt;&lt;P&gt;f = f + g In all selected lines, the contents of the ABAP/4 field or literal g is added to the value in the database table column determined by f . The NULL value remains unchanged. This statement can only be applied to a numeric field. &lt;/P&gt;&lt;P&gt;f = f - g In all selected lines, the contents of the ABAP/4 field or literal g is subtracted from the value in the database table column determined by f . The NULL value remains unchanged. This statement can only be applied to a numeric field. &lt;/P&gt;&lt;P&gt;When the command has been executed, the system field SY-DBCNT contains the number of updated lines. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The return code value is set as follows: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SY-SUBRC = 0 At least one line was updated, &lt;/P&gt;&lt;P&gt;SY_SUBRC = 4 No line was updated because no line could be selected. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note&lt;/P&gt;&lt;P&gt;With pooled and cluster tables, an UPDATE cannot change any primary key field. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Examples&lt;/P&gt;&lt;P&gt;Update discount for all customers (in the current client) to 3 percent: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES SCUSTOM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE SCUSTOM SET DISCOUNT = '003'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note&lt;/P&gt;&lt;P&gt;The 'colon and comma' logic in the program fragment &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE SCUSTOM SET: DISCOUNT  = '003',&lt;/P&gt;&lt;P&gt;                    TELEPHONE = '0621/444444'&lt;/P&gt;&lt;P&gt;              WHERE ID        = '00017777'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;defines record chains, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;not through a single statement which updates the discount and the telephone number of the customer with the customer number '00017777', &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but by means of two statements where the first updates the discount for all customers and the second changes the telephone number of the customer with the customer number '00017777'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition 1&lt;/P&gt;&lt;P&gt;... WHERE condition &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Updates only those lines which satisfy the WHERE clause condition . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example&lt;/P&gt;&lt;P&gt;Increase the number of occupied seats on Lufthansa flight 0400 on 28.02.1995 by 3 (in the current client): &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES SFLIGHT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE SFLIGHT SET   SEATSOCC = SEATSOCC + 3&lt;/P&gt;&lt;P&gt;               WHERE CARRID   = 'LH'   AND&lt;/P&gt;&lt;P&gt;                     CONNID   = '0400' AND&lt;/P&gt;&lt;P&gt;                     FLDATE   = '19950228'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition 2&lt;/P&gt;&lt;P&gt;... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Switches off automatic client handling. This allows you to update across all clients when using client-specific tables. The client field is treated like a normal table field, for which you can formulate suitable conditions in the WHERE clause. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This addition must immediately follow the database table name. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example&lt;/P&gt;&lt;P&gt;Increase the number of occupied seats on Lufthansa flight 0400 on 28.02.1995 by 3 in client 2: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES SFLIGHT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE SFLIGHT CLIENT SPECIFIED&lt;/P&gt;&lt;P&gt;               SET   SEATSOCC = SEATSOCC + 3&lt;/P&gt;&lt;P&gt;               WHERE MANDT    = '002'  AND&lt;/P&gt;&lt;P&gt;               WHERE CARRID   = 'LH'   AND&lt;/P&gt;&lt;P&gt;                     CONNID   = '0400' AND&lt;/P&gt;&lt;P&gt;                     FLDATE   = '19950228'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variant 2&lt;/P&gt;&lt;P&gt;UPDATE dbtab. or &lt;/P&gt;&lt;P&gt;UPDATE *dbtab. or &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) ... . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Additions&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. ... FROM wa &lt;/P&gt;&lt;P&gt;2. ... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;These are SAP-specific short forms which update one single line of a database table. The primary key for identifying the line to be updated and the values to be changed when specifying the database table name in the program are taken from the table work area - dbtab or *dbtab . If the database table name is determined at runtime, you need to use the addition ... FROM wa . &lt;/P&gt;&lt;P&gt;When the command has been executed, the system field SY-DBCNT contains the number of updated lines (0 or 1). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The return code value is set as follows: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SY-SUBRC = 0 The specified line was updated, &lt;/P&gt;&lt;P&gt;SY_SUBRC = 4 No line was updated because no line with the specified primary key exists. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Examples&lt;/P&gt;&lt;P&gt;Update discount for the customer with the customer number '00017777' to 3 percent (in the current client): &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES SCUSTOM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SCUSTOM-ID       = '00017777'.&lt;/P&gt;&lt;P&gt;SCUSTOM-DISCOUNT = '003'.&lt;/P&gt;&lt;P&gt;UPDATE SCUSTOM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition 1&lt;/P&gt;&lt;P&gt;... FROM wa &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Takes the values for the line to be updated not from the table work area dbtab , but from the explicitly specified work area wa . Here, the data is taken from wa , moving from left to right according to the structure of the table work area dbtab (defined with TABLES ). Since the structure of wa is ignored, the work area wa must be at least as wide (see DATA ) as the table work area dbtab and the alignment of the work area wa must correspond to the alignment of the table work area. Otherwise, a runtime error occurs &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example&lt;/P&gt;&lt;P&gt;Update the telephone number of the customer with the customer number '12400177' in the current client: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES SCUSTOM.&lt;/P&gt;&lt;P&gt;DATA   WA LIKE SCUSTOM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WA-ID        = '12400177'.&lt;/P&gt;&lt;P&gt;WA-TELEPHONE = '06201/44889'.&lt;/P&gt;&lt;P&gt;UPDATE SCUSTOM FROM WA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note&lt;/P&gt;&lt;P&gt;If you do not explicitly specify a work area, the values for the line to be updated are taken from the table work area dbtab , even if the statement appears in a FORM or FUNCTION where the table work area is held in a formal parameter or a local variable. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition 2&lt;/P&gt;&lt;P&gt;... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Like variant 1. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variant 3&lt;/P&gt;&lt;P&gt;UPDATE dbtab FROM TABLE itab. or &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) FROM TABLE itab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Mass update of several lines in a database table. Here, the primary key for identifying the lines to be updated and the values to be changed are taken from the lines of the internal table itab . The lines of the internal table must satisfy the same conditions as the work area wa in addition 1 to variant 2. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The system field SY-DBCNT contains the number of updated lines, i.e. the number of lines in the internal table itab which have key values corresponding to lines in the database table. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The return code value is set as follows: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SY-SUBRC = 0 All lines from itab could be used to update the database table. &lt;/P&gt;&lt;P&gt;SY_SUBRC = 4 At least one line of the internal table itab in the database table, had no line with the same primary key. The other lines of the database table were updated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note&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;P&gt;&lt;/P&gt;&lt;P&gt;Addition&lt;/P&gt;&lt;P&gt;... CLIENT SPECIFIED &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect&lt;/P&gt;&lt;P&gt;Like variant 1. &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;Sreeni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 17:54:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550379#M249738</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T17:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550380#M249739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi KPR,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE only updates values in the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You might of refering to MOFIDY when you say if it ever inserts records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Syntax for Update is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. UPDATE  dbtab      SET f1 ... fn. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) SET f1 ... fn. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. UPDATE  dbtab      FROM wa. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) FROM wa. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. UPDATE  dbtab      FROM TABLE itab. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;UPDATE (dbtabname) FROM TABLE itab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. UPDATE  dbtab. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;UPDATE *dbtab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and for MODIFY is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. MODIFY  dbtab      FROM wa. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;MODIFY (dbtabname) FROM wa. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. MODIFY  dbtab      FROM TABLE itab. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;MODIFY (dbtabname) FROM TABLE itab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. MODIFY  dbtab. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;MODIFY *dbtab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. MODIFY  dbtab VERSION vers. or &lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;MODIFY *dbtab VERSION vers. &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;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 17:57:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550380#M249739</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T17:57:06Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550381#M249740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Srini,&lt;/P&gt;&lt;P&gt;Thx for your response. I have read this document already. This "UPDATES" the Dbtab. that is fine. &lt;/P&gt;&lt;P&gt;My question is...Is update work like "INSERT" statement at any point?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 18:01:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550381#M249740</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T18:01:24Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550382#M249741</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi KPR,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;No, update will not work like insert..MODIFY works like INSERT..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 18:07:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550382#M249741</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T18:07:20Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550383#M249742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If I understood your question right, the answer is no.  You can however use MODIFY which basically inserts a new record if the key fields are not found and if they are found updates with the new values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hith&lt;/P&gt;&lt;P&gt;Sunil Achyut&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 18:08:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550383#M249742</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T18:08:37Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550384#M249743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thx Vivek. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I have read in one book as "update" works like "insert" if there is no matching key fields...thats why I wanted to confirm if this would happen to use.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;THANK YOU.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 18:13:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550384#M249743</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T18:13:55Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550385#M249744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi KPR,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't think so...you can double check in the book.&lt;/P&gt;&lt;P&gt;Please award useful replies and close the thread if it is answered.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vivek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 19:09:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550385#M249744</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T19:09:22Z</dc:date>
    </item>
    <item>
      <title>Re: Update query</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550386#M249745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;   Update modifies record If exist or else&lt;/P&gt;&lt;P&gt;   returns subrc as 4.&lt;/P&gt;&lt;P&gt;    but modify statement creates new record &lt;/P&gt;&lt;P&gt;    if record not present.&lt;/P&gt;&lt;P&gt;   say ztest table has two fields&lt;/P&gt;&lt;P&gt;   matnr werks&lt;/P&gt;&lt;P&gt;    ztest-matnr = 'TEST'&lt;/P&gt;&lt;P&gt;    ztest-werks = '1100'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   modify ztest.            &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Amole&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 19:50:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-query/m-p/1550386#M249745</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T19:50:17Z</dc:date>
    </item>
  </channel>
</rss>

