PostgreSQL: insert string in a large object from an SQL script without relying on an external file

Viewed 3065

I know it's possible to insert into a large object from a PostgreSQL script using a lo_import():

INSERT INTO image (name, raster)
VALUES ('beautiful image', lo_import('/etc/motd'));

Te problem is, I'm trying to execute a script on a tightly locked up server, so I can't upload a file to it. Is it possible to insert a constant string into a large object without relying on an external file?

1 Answers
Related