From: | Julius Tuskenis <julius(dot)tuskenis(at)gmail(dot)com> |
---|---|
To: | |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Load Image File From PostgreSQL DB |
Date: | 2008-12-30 16:06:53 |
Message-ID: | 495A471D.7090807@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hello, Albe
In the article you provided it is said that "The return value is the OID
that was assigned to the new large object..." (function Oid
lo_creat(PGconn *conn, int mode);). That means that not the large object
is stored in OID field - its just the reference to it.
Any way I find it much easier to get a relatively small blob in a result
set and not directly using lo_read function, because in delphi zeos
components does work with libpq, so theres no need to bypass them?
Julius Tuskenis
Albe Laurenz rašė:
> dbalinglung wrote:
>
>>> I seriously doubt you could store an image in oid typed column, because
>>> "The oid type is currently implemented as an unsigned four-byte
>>> integer." (from postgresql 8.2 manual). I too use Zeos with no problems
>>> using bytea type.
>>>
>> Ok, I'll try your sugestion, many thanks bro.
>>
>
> Large Objects (http://www.postgresql.org/docs/current/static/largeobjects.html)
> use OID columns, and they work fine for storing binary data like images.
>
> But bytea will work just as fine.
>
> Yours,
> Laurenz Albe
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Reg Me Please | 2008-12-30 16:08:41 | Re: [PGSQL 8.3.5] Use of a partial indexes |
Previous Message | Albe Laurenz | 2008-12-30 15:39:23 | Re: Load Image File From PostgreSQL DB |