<?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: simultaneous insert in a z table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465540#M1554428</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; hi sri&lt;/P&gt;&lt;P&gt;&amp;gt; another question&lt;/P&gt;&lt;P&gt;&amp;gt; when doing the INSERT, its not necessary to specify the field time&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;gt; i just have to define this field, UZEIT TYPE SY-UZEIT and during the INSERT, this field will be populated automatically, right?&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nope.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But again: i bet you still will have some duplicates. So just go for your own number range object for your key field. Than you'll know the value will be unique.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To clarify: you said &lt;STRONG&gt;at the same time&lt;/STRONG&gt;'. What time will be in that UZEIT field if you get the time for several users &lt;STRONG&gt;at the same time&lt;/STRONG&gt; ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It's the value of your key field that must be unique,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Dec 2010 11:38:01 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-12-08T11:38:01Z</dc:date>
    <item>
      <title>simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465532#M1554420</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi everyone&lt;/P&gt;&lt;P&gt;in a program, im doing an INSERT into a ztable from an internal table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now this program is getting executed by several users at the same time and the program is getting a short dump &lt;/P&gt;&lt;P&gt; The ABAP/4 Open SQL array insert results in duplicate database records.     &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anybody can help me how i can handle this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried to replace INSERT by MODIFY but its not working&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:09:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465532#M1554420</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:09:57Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465533#M1554421</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 cannot insert duplicate values into the table using INSERT statement. MODIFY or UPDATE would work but that would overwrite the date with the same key fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this table is used to maintain some log, then you have to use INSERT and to help further please post the key fields in the table ? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:16:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465533#M1554421</guid>
      <dc:creator>sridhar_meesala</dc:creator>
      <dc:date>2010-12-08T11:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465534#M1554422</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the key field is an ID of 6 characters&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:20:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465534#M1554422</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:20:24Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465535#M1554423</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;As you said earlier, that different users may insert records at the same time and if the table contains some time field then that would give a dump for having duplicate values. So you better make the time field along with the ID as a key field in the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:24:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465535#M1554423</guid>
      <dc:creator>sridhar_meesala</dc:creator>
      <dc:date>2010-12-08T11:24:22Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465536#M1554424</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Define your own number range object for your key field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Look at transaction SNRO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you said earlier, that different users may insert records at the same time and if the table contains some time field then that would give a dump for having duplicate values. So you better make the time field along with the ID as a key field in the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is still a change to have duplicates.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:31:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465536#M1554424</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:31:07Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465537#M1554425</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;its a good idea&lt;/P&gt;&lt;P&gt;i'll try to do that&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:31:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465537#M1554425</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:31:46Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465538#M1554426</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi sri&lt;/P&gt;&lt;P&gt;another question&lt;/P&gt;&lt;P&gt;when doing the INSERT, its not necessary to specify the field time&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i just have to define this field, UZEIT TYPE SY-UZEIT and during the INSERT, this field will be populated automatically, right?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:35:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465538#M1554426</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:35:34Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465539#M1554427</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;Before inserting the data into internal table we need to check whether that data is already available in database or not.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if the data is already in database no need to insert the data.Then if parallel users are using no problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STEP1:Select the data from table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STEP2:LOOP The data and check the data whether data is already there or not.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STEP3:Other wise insert the data into table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;muralii.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:36:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465539#M1554427</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:36:49Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465540#M1554428</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; hi sri&lt;/P&gt;&lt;P&gt;&amp;gt; another question&lt;/P&gt;&lt;P&gt;&amp;gt; when doing the INSERT, its not necessary to specify the field time&lt;/P&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&amp;gt; i just have to define this field, UZEIT TYPE SY-UZEIT and during the INSERT, this field will be populated automatically, right?&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nope.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But again: i bet you still will have some duplicates. So just go for your own number range object for your key field. Than you'll know the value will be unique.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To clarify: you said &lt;STRONG&gt;at the same time&lt;/STRONG&gt;'. What time will be in that UZEIT field if you get the time for several users &lt;STRONG&gt;at the same time&lt;/STRONG&gt; ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It's the value of your key field that must be unique,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:38:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465540#M1554428</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:38:01Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465541#M1554429</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi maen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with the field uzeit, hows its possible to have the dump?there will always be a difference of 1 second, isnt it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:44:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465541#M1554429</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:44:46Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465542#M1554430</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i think i must make user as well a key field&lt;/P&gt;&lt;P&gt;the users dont want to go for the option of object range&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is making the id, time and user the key fields a plausible solution?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:47:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465542#M1554430</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:47:13Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465543#M1554431</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with the field uzeit, hows its possible to have the dump?there will always be a difference of 1 second, isnt it? &lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nope. Not always.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why not a number range?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:47:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465543#M1554431</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:47:22Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465544#M1554432</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; is making the id, time and user the key fields a plausible solution?&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sure it's plausible. You may add date as well. And their date of birth... and their zipcode. And the date of birth of their firstborn child... the name of their secret lover...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why complicate things if you can solve it easily with just a simple number range?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 11:51:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465544#M1554432</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T11:51:37Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465545#M1554433</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Prema,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why don't you make use of lock objects on the table?&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;Jaya krishna.K&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 12:22:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465545#M1554433</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T12:22:59Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465546#M1554434</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry if it sounds a bit out of context, but wouldnt this be a perfect scenario for a enqueue/dequeue process?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 12:24:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465546#M1554434</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T12:24:00Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465547#M1554435</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; Sorry if it sounds a bit out of context, but wouldnt this be a perfect scenario for a enqueue/dequeue process?&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Would that be a viable option when only inserting new records?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Truth be told: i have no clue what the purpose of his Z-table is and whether he only inserts new records or also need to update existing ones.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 12:28:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465547#M1554435</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T12:28:28Z</dc:date>
    </item>
    <item>
      <title>Re: simultaneous insert in a z table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465548#M1554436</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Maen&lt;/P&gt;&lt;P&gt;Ive done the number range&lt;/P&gt;&lt;P&gt;needs to test it&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Dec 2010 12:51:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/simultaneous-insert-in-a-z-table/m-p/7465548#M1554436</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-12-08T12:51:01Z</dc:date>
    </item>
  </channel>
</rss>

