FAQ
Hi,

currently I've problems using DBD::Proxy with AutoCommit set to off.
$dbh->commit is ignored completely, but $dbh->rollback works.

This little script reproduces the behaviour:

--snip--
#!/usr/local/bin/perl

use strict;
use DBI;
use Data::Dumper;

main: {
my $source;
$source = "dbi:Proxy:hostname=merlot;port=12121;dsn=dbi:Oracle:";
# $source = "dbi:Oracle:";

my $dbh = DBI->connect (
$source, $ENV{TESTUSER}, $ENV{TESTPASSWD},
{ RaiseError => 1, AutoCommit => 0 }
);

$dbh->do ("drop table dbdproxy") if @ARGV;
eval { $dbh->do ("create table dbdproxy ( id integer )") };

$dbh->do ("insert into dbdproxy values ( ? )", undef, $$);
print Dumper($dbh->selectall_arrayref ("select id from dbdproxy"));

$dbh->commit;

END { if ( $dbh ) { $dbh->rollback; $dbh->disconnect; } }
}
--snip--

If I run this script twice, to records should appear in the table. But I
see only the one inserted in the current transaction:

joern@merlot:~ > ./dbdproxy
$VAR1 = [
[
19149
]
];

joern@merlot:~ > ./dbdproxy
$VAR1 = [
[
19175
]
];

If I connect directly through DBD::Oracle, everything works as expected.

I'm using Linux, Perl 5.005_03 and DBI 1.15 with the shipped DBD::Proxy
version. A Linux Oracle 8.17 Enterprise Edition is connected, using
DBD::Oracle 1.06.


Is this a DBD::Proxy bug? Or do I miss something?

Thanks,

Joern

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupdbi-users @
categoriesperl
postedMay 14, '01 at 4:07p
activeMay 15, '01 at 8:44a
posts2
users1
websitedbi.perl.org

1 user in discussion

Joern Reder: 2 posts

People

Translate

site design / logo © 2022 Grokbase