See "Programming with CGI.pm" by Lincoln Stein for instructions on how to:
"... get the uploaded file onto the local filesystem (via the
multipart form thingie) ..."

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Orlando Andico
> Sent: Wednesday, January 24, 2001 11:21 PM
> To: surfer girl
> Cc: [EMAIL PROTECTED]
> Subject: Re: BLOB: CGI->DBI->Oracle
>
>
>
> On Wed, 24 Jan 2001, surfer girl wrote:
> ..
> > I have gone through numerous list archives, tons of docs, a zillion
> > websites it seems, and I have yet to find a simple example of the
> > following: uploading and inserting a binary file (such as an image)
> > into the BLOB field of an Oracle database (v.8) using Perl DBI and
> > CGI.pm. Then selecting it and displaying it once it's in there!
>
> Assuming you can get the uploaded file onto the local filesystem (via the
> multipart form thingie) then the blob insert is TRIVIAL. all you need to
> do is insert the whole data thing (load it into a scalar first) via a
> placeholder.
>
> recovery is only slightly more complicated. you don't have to follow the
> recover-by-frags method described in the DBD::Oracle docs. just fetch
> normally into a scalar, but remember to set
>
> $dbh->{LongReadLen} = somevalue;
>
> BEFORE doing the select, where somevalue should probably be larger than
> the larger blob you'll ever store, that way you can fetch the blob with
> just one fetch, instead of looping.
>
>
> ---------------------------------------------------------------------
> Orlando Andico <[EMAIL PROTECTED]>       POTS Phone: +63   (2) 937-2293
> Mosaic Communications, Inc.            GSM Mobile: +63 (917) 531-5893
> I'm not suffering from insanity -- I'm enjoying  every minute of it!!
>
>
>
> ------------------------------------------------------------------
> ------------
> DBI HOME PAGE AND ARCHIVES:
http://www.symbolstone.org/technology/perl/DBI/
To unsubscribe from this list, please visit:
http://www.isc.org/dbi-lists.html
If you are without web access, or if you are having trouble with the web
page,
please send mail to [EMAIL PROTECTED] with the subject line of:
'unsubscribe'.
----------------------------------------------------------------------------
--


Reply via email to