Re: DBD::Pg`s $dbh->func( "/path/to/file", `lo_import` ) fails silently - Mailing list pgsql-general

From Kynn Jones
Subject Re: DBD::Pg`s $dbh->func( "/path/to/file", `lo_import` ) fails silently
Date
Msg-id c2350ba40903191205s2076a3b2n7785e3e852b75955@mail.gmail.com
Whole thread Raw
In response to Re: DBD::Pg`s $dbh->func( "/path/to/file", `lo_import` ) fails silently  ("Greg Sabino Mullane" <greg@turnstep.com>)
Responses Re: DBD::Pg's $dbh->func( "/path/to/file", 'lo_import' ) fails silently  ("Greg Sabino Mullane" <greg@turnstep.com>)
List pgsql-general
On Wed, Mar 18, 2009 at 3:57 PM, Greg Sabino Mullane <greg@turnstep.com> wrote:

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160


> I'm trying to use Perl's DBD::Pg module to import a file as a large object.
> For this I'm using the following:
> my $oid = $dbh->func( "/absolute/path/to/file", 'lo_import' );

Works fine for me. What version of DBD::Pg are you using? Try something
recent if you are using something old. You can also set the trace
level to see what's going on behind the scenes:

$dbh->trace(10)

Thanks for your reply.

Actually, after much trial and error I figured out the problem: the handle I was using had AutoCommit set.  I'm new to the lo_* functions, and not aware of this issue.  A mention of this in the DBD::Pg docs would be very helpful to LO noobs like me.

Cheers,

Kynn

pgsql-general by date:

Previous
From: Raymond O'Donnell
Date:
Subject: Re: Installation Error, Server Won't Start
Next
From: "Joshua D. Drake"
Date:
Subject: PostgreSQL technical Videos: Proteomic mining and Procedural language development