Re: problems with commit and oracle

From: Date: Thu, 25 May 2000 09:06:13 +0000
Subject: Re: problems with commit and oracle
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-515@lists.php.net to get a copy of this message
On Wed, May 24, 2000 at 01:40:27PM -0400, Leandro Martelli wrote: > Hi people! > > Anyone has any idea why aborted (or ending) > scripts do commit, instead of rollback ? > ( i?m oracle using oci*) > > So, how do I turn autocommit OFF?? > (OCI_DEFAULT doesn?t work in the following > script. The script reaches its end and > no explicit commit is done, but "foo-bar" is > included in the table, as seen with SQL*Plus) > > -------------------------------------- > (I?m using PHP 3.0.16 (also PHP4 RC1), Oracle > 8.1.5) > > <? > $int_handle = 0; > $stmt = 0; > > $int_handle = OCILogon > ("mylogin", "mypass", "mySID"); > > if (!$int_handle) > exit; > > $query="insert into tablename (name) values > ('foo-bar')"; > > $stmt = OCIParse($int_handle, $query); > > if (!$stmt) > exit; > > OCIExecute($stmt, OCI_DEFAULT); > > ?> > -------------------------------------- > > Thanx all. fixed in PHP 4 and PHP 3 CVS. thanx for pointing it out! > > > > ________________________________________________ > Get your own "800" number - Free > Free voicemail, fax, email, and a lot more > http://www.ureach.com/reg/tag > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net -- Thies C. Arntzen "One Big-Mac, Small Fries and a Coke!" Digital Collections Phone +49 40 235350 Fax +49 40 23535180 Hammerbrookstr. 93 20097 Hamburg / Germany

« previous php.general (#515) next »