From: | Daniel Schuchardt <daniel_schuchardt(at)web(dot)de> |
---|---|
To: | Edwin Quijada <listas_quijada(at)hotmail(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Picture with Postgres and Delphi |
Date: | 2003-09-09 18:41:35 |
Message-ID: | 1063132895.656.32.camel@ds-debian |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi Edwin,
it depends on the components u use in Delphi. Normally Pictures and
ohter binary data is stored in the FieldType oid. I noticed that bytea
isn't mapped as TBlobField in Delphi in most components. I also don't
know if you are able to use the PG-Functions lo_import(), lo_export()
and so on with bytea. I use oid with Delphi and that works fine for me.
In Delphi you can use Procedures like TBlobField(MyField).LoadFromFile.
Post a Picture to the Server will look like this :
DataSet.Insert;
DataSet.BlobField.LoadFromFile('MyPictureFile');
DataSet.Post;
Now your pitcure is on the Server. You are also able to use standard
DBPicture-components...
Daniel
Am Di, 2003-09-09 um 18.54 schrieb Edwin Quijada:
> Hi !! Everybody
> I am developing app using Delphi and I have a question:
> I have to save pictures into my database. Each picture has 20 o 30k aprox.
> What is the way more optimus?
> That 's table will have 500000 records around. Somebody said the best way to
> do that was encoder the picture to field bytea but I dont know about this.
> Another way is save the path to the picture file but I dont like so much
> because I need to write to disk by OS and have permission to write a
> directory to OS.
> What do u think??
> Edwin Quijada
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
From | Date | Subject | |
---|---|---|---|
Next Message | Joseph Shraibman | 2003-09-09 18:42:11 | Re: Unix domain instead of TCP socket connections with |
Previous Message | kaab kaoutar | 2003-09-09 18:36:48 | to_timestamp and to_date fails in postgresql 7.1.3 |