I have nearly the same problem as you seem to have.
I am able to store and retrieve files in a PostgreSQL database.
However i only can save and get files wich are on the Linux box where my
postgres server is running.
Is this the case with your problem too ??
Anyway if i tell my visual basic application that it has to store and
retrieve files on the PC (running windows) than i don't have success.
Saving files at the Linux box is no problem.
I do it the following way
This is the SQL statement in the ODBC string. (exporting data on the linux
SELECT lo_export(juancol.photo,'/tmp/photo') FROM juancol juancol WHERE
(importing data from the linux machine)
INSERT INTO juancol (juancol.name, juancol.photo) VALUES ('nicephoto',
I think it is a good idea to work with a unique key to get the photo and to
store the photo, so that we do not get misunderstandings.
Do not forget to think of setting open the directory for writing, with chmod
xxx or something.
I hope this will work for you .
Anyway my problem is that i can not write or read to a PC directly..
Did you solve this with psql ???
Rudolf ter Haar.
Juan Colmenares wrote:
> I'm trying to store a jpeg file into a table created as follow:
> CREATE TABLE juancol (
> name text,
> photo oid
> I can insert a jpeg file from pgsql (locally) but I can not do this from
> application written in Visual Basic using an ODBC driver (V06-40-0006).
> I read psqlodbc FAQs (Can I use large objects or OLE?) but I wouldn't
> have to deal with clean-up tasks.
> Someone could tell me any suggestion?
> Thanks in advance!
> Juan Andres.
In response to
pgsql-interfaces by date
|Next:||From: Hiroshi Inoue||Date: 1999-11-23 13:17:40|
|Subject: Re: [INTERFACES] table very big !!!!!|
|Previous:||From: Rafal Piotrowski (CSCS)||Date: 1999-11-23 11:19:51|
|Subject: LargeObject.write(byte buf) method|