Subject Re: [firebird-support] How do I Store/Retrieve graphics to/from BLOBs using IBQuery?
Author Martin
This might work for you, this answer might be a bit quicker. Again as heLen
says this is not a programming related list.

// Setup the parameters
IBQuery1.SQL.Text := 'Insert into MyTest Values(:ImageFile)'; //....
replace with your sql
IBQuery1.ParamByName('Image').ParamType := ptInput;
IBQuery1.ParamByName('Image').DataType := ftBlob;

// setting the blob parameter in the procedure call is important
// even though it has already been defined

// execute the query


At 07:17 PM 14/08/03 -0500, you wrote:

> > Hi All,
> >
> > I'm trying to store and retrieve graphics (Bitmaps and JPEGs)
> > to/from a BLOB field in one of my Firebird (1.5) Tables. I've looked
> > all over the place for the answer and the only ones I can find
> > involve TFields and TIBTables but I need to use a TIBQuery.
> >
> > I'm thinking along the lines of creating a Param and streaming the
> > graphic to/from it. Unfortunately I'm at a loss as to how to do it.
> >
> > Thanks for any help you can give me.
>As Helen says, this isn't a Delphi list. But, if you mention Firebird on the
>Delphi list, you will mainly get redirected here, as well. If my answer
>doesn't help enough, post this question in
>borland.public.delphi.interbaseexpress without mentioning Firebird.
>You need to utilize the streaming methods of the graphics components or a
>graphic file. Use a TIBBlobStream created with the CreateBlobStream method
>of the TIBQuery. Then, you can use the CopyFrom stream method to copy from
>one to the other.
>Woody (TMW)
>Freeware Page:
>Success always occurs in private, and failure in full view.
>To unsubscribe from this group, send an email to:
>Your use of Yahoo! Groups is subject to
>Incoming mail is certified Virus Free.
>Checked by AVG anti-virus system (
>Version: 6.0.509 / Virus Database: 306 - Release Date: 12/08/03


Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (
Version: 6.0.509 / Virus Database: 306 - Release Date: 12/08/03

[Non-text portions of this message have been removed]