Erwin Brandstetter wrote:
Hi!
What I want to do:
Import a file from the file system into a bytea field of a table.
Now, I could copy over from pg_largeobject:
And create a large object and export from there as above.
But that seems unnecessarily complex, and .. well .. stupid.
There
On Mar 5, 10:20 am, [EMAIL PROTECTED] (Richard Huxton) wrote:
Erwin Brandstetter wrote:
Hi!
What I want to do:
Import a file from the file system into a bytea field of a table.
(...)
Not that I know of. It's simple enough to do from the application side
of things of course (well, in most
On 3/5/08, Erwin Brandstetter [EMAIL PROTECTED] wrote:
The whole concept behind large objects is a bit off. Since we have
TOAST tables, it is of limited use to store large objects away in a
system table. It would be useful to have (additional) functions like:
lo_import(text) RETURNS
Hi!
What I want to do:
Import a file from the file system into a bytea field of a table.
I know how to do it with large objects:
INSERT INTO mytable(oid_fld) VALUES (lo_import('/mypath/myfile'));
And export from there:
SELECT lo_export(oid_fld, '/mypath/myfile2') FROM mytable WHERE
some