Re: psql and \lo_import - Mailing list pgsql-general

From Howard Lowndes
Subject Re: psql and \lo_import
Date
Msg-id Pine.LNX.4.44.0309230655390.2808-100000@int.lannet.com.au
Whole thread Raw
In response to Re: psql and \lo_import  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Mon, 22 Sep 2003, Tom Lane wrote:

> Howard Lowndes <lannet@lannet.com.au> writes:
> > I'm working psql v7.2.2 to postmaster v7.2.2 and want to use the
> > \lo_import function.
> > The psql manual says that the syntax is \lo_import '<filename>' 'comment'
> > This loads the blob OK and returns the loid but the comment gets lost and
> > doesn't appear when I run \lo_list
>
> I think the comment-on-LO facility only works if you are superuser
> (because it's hacking a system table, there not being any actual
> COMMENT ON LARGE OBJECT command).

I hear what you say, but the psql manual specifically mentions that the
difference between the \lo_import command and the server-side lo_import
function is that the former "acts as the local user on the local file
system, rather than the server's user and file system".  If this is the
case then why do they not specifically mention the superuser restriction
in the syntax.

To my mind this impies that this restriction (to be the superuser) does
not apply to the \lo_import command.

Further, the blob is loaded into pg_largeobject table, which surely, is a
system table.

--
Howard.
LANNet Computing Associates - Your Linux people <http://www.lannetlinux.com>
------------------------------------------
Flatter government, not fatter government - Get rid of the Australian states.
------------------------------------------
If all economists were laid end to end, they would not reach a conclusion
- George Bernard Shaw


pgsql-general by date:

Previous
From: Jan Wieck
Date:
Subject: Re: Rockets (was Re: PostgreSQL versus MySQL)
Next
From: "Joshua D. Drake"
Date:
Subject: Re: State of Beta 2