Subject | Re: [IBO] Passing Blobs to an Insert or Update Query |
---|---|
Author | Helen Borrie |
Post date | 2004-06-08T04:25:02Z |
At 03:18 AM 8/06/2004 +0000, you wrote:
between the vcl units db.pas (which the TIBO components use) and DBTables
(which TIBO does not use).
Try
TIB_ColumnBlob(ParamByName('BARCODE')).LoadFromFile(sJPEGFile);
An unsolicited comment on your code here: why waste resources by assigning
SQL at runtime and not parameterising *both* of these inputs?
Helen
>Hmmm.... I can't seem to pass blobs to an update or insert query.I seem to recall there's a problem with TBlobField due to some dependency
>Any ideas?
>
> sQ :=
> 'INSERT into SIGNATURES ' +
> '(SINVLOOKUP, BARCODE) Values '+
> '('+ QuotedStr(sInvLookup) + ', :Barcode)';
> Active := False;
> SQL.Clear;
> SQL.Add(sQ);
> TBlobField(ParamByName('BARCODE')).LoadFromFile(sJPEGFile);
> Active := True;
between the vcl units db.pas (which the TIBO components use) and DBTables
(which TIBO does not use).
Try
TIB_ColumnBlob(ParamByName('BARCODE')).LoadFromFile(sJPEGFile);
An unsolicited comment on your code here: why waste resources by assigning
SQL at runtime and not parameterising *both* of these inputs?
Helen