#1  
Old 13th April 2004, 09:38 PM
Eivind Bakkestuen [NDD]
 
Posts: n/a
Default Re: Multiple changes, one transaction, with SQL

> If I perform multiple inserts/changes in one single SQL execution,
> (multiple instructions separated by semicolons), are they performed
> in a single transaction (if one fail, all fail)?


My apologies! I have just been informed by Per that the answer to this
question is... NO. Each individual statement inside the larger one is run in
its own transaction.

So, take note: To ensure data integrity using SQL and multiple statements
separated by ";", you should start a transaction first, then run a
multi-statement query, then commit or rollback as appropriate.

--

Eivind Bakkestuen [NDD]
Please, no email unless requested.
Search Borland and third-party newsgroups here: www.tamaracka.com


  #2  
Old 14th April 2004, 06:02 AM
Hugo Galindo
 
Posts: n/a
Default Re: Multiple changes, one transaction, with SQL

Eivind Bakkestuen [NDD] wrote:
....
> My apologies! I have just been informed by Per that the answer to this
> question is... NO. Each individual statement inside the larger one is run in
> its own transaction.
>
> So, take note: To ensure data integrity using SQL and multiple statements
> separated by ";", you should start a transaction first, then run a
> multi-statement query, then commit or rollback as appropriate.
>
>


I took note

Thanks Eivind

--
Hugo Galindo


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Host spawning multiple copies Hannes Danzl[NDD] nexusdb.public.support.portal 4 18th October 2010 06:17 AM
Multiple uploads Charalampos Michael nexusdb.public.support.portal 19 20th October 2009 11:49 AM
Re: Multiple changes, one transaction, with SQL Hugo Galindo nexusdb.public.support.sql 2 7th April 2004 12:05 PM
Transaction Processing William E. Mahaffey nexusdb.public.support.sql 2 23rd October 2003 01:51 AM
Update multiple columns William E. Mahaffey nexusdb.public.support.sql 1 16th October 2003 09:00 AM


All times are GMT +11. The time now is 05:52 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.