pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Purusothaman A <purusothaman.a@gmail.com>
To: Milen A. Radev <milen@radev.net>
To: pgsql-admin@postgresql.org
To: pgsql-general@postgresql.org
Subject: Re: Problem with lo_export() and lo_import() from remote machine.
Date: Sat, 9 Sep 2006 17:19:26 +0530
Message-ID: <3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com> (raw)
In-Reply-To: <edu8r6$k56$1@sea.gmane.org>
References: <3650d0d50609090407j237bb710h9bde1675c773925d@mail.gmail.com>
	<edu8r6$k56$1@sea.gmane.org>

Hi Milen A. Radev,

Thank you for your response.

I have read this in PostgreSQL documentation.

I usually log in to postgresql server with admin username.

But whatever its, according to documentation, if client machine's user has
write access
permission, this query should successfully be executed.

Both PostgreSQL server/client are Windows XP machines.

Any suggestion???

:)
Purusothaman A

On 9/9/06, Milen A. Radev <milen@radev.net> wrote:
>
> Purusothaman A написа:
> > Hi all,
> >
> > I have problem while using "lo_export()" and "lo_import()" from remote
> > system.
> >
> > eg:
> > ****
> > select lo_export(img_file, 'E:\\temp\\1001.jpg') from master where
> emp_id =
> > '1001';
> > insert into master(img_file) values(lo_import('E:\\temp\\1001.jpg'))
> where
> > emp_id = '1001';
> >
> > Here column "img_file" is OID data type.
> >
> > The above query works, if I enter from PostgreSQL server machine.
> > But the same query fails, if I enter from any other client machine in my
> > LAN.
> >
> > All other queries work well from remote machine, which do not deal OID
> data
> > type column.
> >
> > any suggestions would be appreciated.
> >
>
> Please, RTFM - http://www.postgresql.org/docs/current/static/lo-funcs.html
>
> Quote:
>
> "The server-side lo_import and lo_export functions behave considerably
> differently from their client-side analogs. These two functions read and
> write files in the server's file system, using the permissions of the
> database's owning user. Therefore, their use is restricted to
> superusers. In contrast, the client-side import and export functions
> read and write files in the client's file system, using the permissions
> of the client program. The client-side functions can be used by any
> PostgreSQL user."
>
>
>
> --
> Milen A. Radev
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: don't forget to increase your free space map settings
>


view thread (15+ messages)  latest in thread

Message-ID: <3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com>
Permalink:  ../3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com/
Also on:    postgresql.org/message-id/3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: purusothaman.a@gmail.com, milen@radev.net, pgsql-general@postgresql.org
  Subject: Re: Problem with lo_export() and lo_import() from remote machine.
  In-Reply-To: <3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com>
  References: <3650d0d50609090407j237bb710h9bde1675c773925d@mail.gmail.com> <edu8r6$k56$1@sea.gmane.org> <3650d0d50609090449q2aec1098xc3b62dd169de5843@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox