storing image (gif) in Oracle

From: <tcblue82_at_my-deja.com>
Date: 2000/08/11
Message-ID: <8n12r1$k8k$1_at_nnrp1.deja.com>#1/1


Hi,
[Quoted] I'm having lots of trouble finding information on how to store binary data in oracle. All I can find is text that tells me i can use the Long Raw datatype to store images, music, etc. but not how to do that. Ok so I am using perl to store things, and i have the following DB statements:

$sth = $shipping->DB->dbh->prepare("UPDATE SHIPPING SET GIF_LABEL = ?
WHERE SHIPPING_ID = ".$shipping->id
) || die $shipping->DB->dbh->errstr;
$sth->execute($gif_label) || die "At execute: ".$sth->errstr;

Basicaly it is this below:
UPDATE SHIPPING SET GIF_LABEL = $GIF_DATA WHERE SHIPPING_ID = 4; where $GIF_DATA is my gif binary gif data (this works because i can print out the gif on the screen using a gif header so i know the data is valid.) OK, this DOES NOT WORK. I am however able to store, say something like 'a', '2', but not 'abc23'. So Would it be something with my setup? I created the column with as a (COLUMN_NAME LONG RAW). If any one has any examples on how to store image data in oracle or any ideas on what could be wrong with my code or setup Please email me or reply to this Post. Thanks!

-Pat-
tcblue82_at_yahoo.com

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Fri Aug 11 2000 - 00:00:00 CEST

Original text of this message