I can only get this to work with DBD::ODBC ...

> #!c:/perl/bin/perl.exe -w
> use DBI;

First you must import constants:

use DBI qw(:sql_types);

And use binary mode for Win32 platform before reading from file:

binmode STDIN;
open(FILE,'C:\temp\test.jpg') or die $!;

> $sth->bind_param( 1, $imagedata, SQL_BINARY );

Wrong bind type, should be SQL_LONGVARBINARY and in your database the field
should have a "Memo" Data Type

--
  Simon Oliver

Reply via email to