Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread add jpeg via sql (Help)
Wed, Jul 26 2006 11:02 PMPermanent Link

Aaron Taylor
does anyone know how to add a jpeg via sql
i tried something like

with MyDBISAMQuery do
  begin
   SQL.Clear;
   SQL.Add('UPDATE table Set imagefield=:MyJPEGField');
   SQL.Add('WHERE Recordno=:num')
   ParamByName('num').asinteger:=5
   ParamByName('MyJPEGField').LoadFromFile('myimage.jpg');
   ExecSQL;
  end;

but got a 'not enough parameters' Error.
Thu, Jul 27 2006 10:35 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Aaron,

<< but got a 'not enough parameters' Error. >>

It's probably this:

ParamByName('MyJPEGField').LoadFromFile('myimage.jpg',ftBlob);  <<< Add the
ftBlob parameter to the call

--
Tim Young
Elevate Software
www.elevatesoft.com

Image