Skip site navigation (1) Skip section navigation (2)

Re: lo_import

From: Fabrízio de Royes Mello <fabriziomello(at)gmail(dot)com>
To: Maurício Cruz <cruz(at)sygecom(dot)com(dot)br>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: lo_import
Date: 2012-01-04 00:01:55
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-admin
Em 3 de janeiro de 2012 17:05, Maurício Cruz <cruz(at)sygecom(dot)com(dot)br> escreveu:

> Hi all,
Hi Mauricio,

> I'm trying to use lo_import to import a file into my database, if I
> execute from postgres runing in my local machine
> it works perfectly, but if I do it in the postgres runing in the server,
> it says "No such file or directory"
It's the default behavior.

I Guess postgres only see file on the machine it is runing and not through
> the network...
> I will have to upload the file into the server and then use import  ?   is
> there any other way ?
The lo_import/lo_export functions read/write files in the same file system
where postgres server is running [1]...

If you need send some file from your client to your database server you
must verify the implementation of libpq API in your programming language to
use another functions (lo_creat, lo_open, lo_write, lo_read) to create LOs
from your client side of connection into your server  [2].

Another way is using "psql" client program [3] to import/export large


Fabrízio de Royes Mello
Consultoria/Coaching PostgreSQL
>> Blog sobre TI:
>> Perfil Linkedin:
>> Twitter:

In response to

  • lo_import at 2012-01-03 19:05:45 from Maurício Cruz

pgsql-admin by date

Next:From: Jeff RuleDate: 2012-01-04 00:19:46
Subject: Re: unix domain sockets on Windows.
Previous:From: TripuraDate: 2012-01-03 21:52:15
Subject: Drop Schema from Postgres

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group