I'm in the same situation. I struggled with it for days
considering various implementation issues for my application
and what I hoped to achieve. I opted to use bytea but getting the
data in and out is going to be interesting . have to use encode/decode.
However I don't have to worry about making triggers and associated
to invoke lo_import/export/unlink.
There is no true BLOB in Postgresql.
There is use of OID column and lo_import et al and there is bytea.
My objective to assure integrity of the database lead me to want bytea.
I am not by any means done with the situation and would welcome
discussion.
I'm using Perl for my application language.
On Wed, 11 Feb 2004, beyaNet Consultancy wrote:
> Hi,
> what I am trying to do is to be able to store images in my database.
> What I wanted to know is this:
>
> 1. Would it be better to have the image field type as a bytea or a
> blob? I have heard it mentioned that bytea would be better as doing
> data dumps would also insure that the image was saved as well!
>
> 2. Would it be better to make reference to mp3 files (i.e. storing the
> address of the image /images/*.jpg) or is it feasible to store the mp3
> in the database as bytea or blobs as well?
>
> many thanks in adavance
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>