-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> I'm trying to figure out how to get large objects working using libpg.
> The problem is that whenever I do an lo_open on an object, I get back
> "-1" as the file descriptor (and of course, an lo_read on that fails).
Large object operations must be done within a transaction. Try issuing
a "begin" before you call lo_creat:
res = PQexec(dbConn, "begin");
PQclear(res);
// Large object stuff goes here....
res = PQexec(dbConn, "end");
PQclear(res);
PQfinish(dbConn);
- --
Greg Sabino Mullane greg@turnstep.com
PGP Key: 0x14964AC8 200305030957
-----BEGIN PGP SIGNATURE-----
Comment: http://www.turnstep.com/pgp.html
iD8DBQE+s8tnvJuQZxSWSsgRAog6AKCAmVAsn0SF8mnrKQiVp+7SdxTZSQCfWvUf
op+BcWSQCJIwyVJ72J8+KUA=
=HMkb
-----END PGP SIGNATURE-----