in reply to Re: How to manage post binary upload with mysql blob fields
in thread How to manage post binary upload with mysql blob fields

Hello and thanks for your help. I read it but I know, how to save an uploaded file. The problem is, that I don't know how to save the uploaded file into a database blob field. Any hints?
  • Comment on Re^2: How to manage post binary upload with mysql blob fields

Replies are listed 'Best First'.
Re^3: How to manage post binary upload with mysql blob fields
by poj (Abbot) on Feb 15, 2011 at 20:52 UTC
    Try reading to $file in blocks
    my $fh = $q->param('myfile'); binmode $fh; my $block; my $file; while ( read($fh,$block,1024) ){ $file .= $block; } insertRessource( $name, $entryid, $file, $mime );
    poj