Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Grafix?

Re: Grafix?

From: Tim McConechy <tmcconec_at_gulf.uvic.ca>
Date: 1998/03/16
Message-ID: <350DA143.1FC3FE95@gulf.uvic.ca>#1/1

Here is some PL/SQL code that I have yet to get working.... Quick answer... use the DBMS_LOB package....

DECLARE
filevar BFILE;
blobvar BLOB;
result INTEGER;
amount INTEGER;
filename CHAR(20);
dir_alias CHAR(100);

BEGIN
--first create a Oracle directory
--using create directory FILEDIRGEOGA as '/oracle/oracle8owner/data';

filevar := BFILENAME('FILEDIRGEO','logo2.gif');

COMMIT;
END;
/

You can use forms too. Create an image_item and call. read_image_item('path to the bmp file','BMP','block_name.image_item_name'); Make sure the block is set up to query a base_table you want to store your image in.
Then hit F10 to commit it to a blob or long raw column. Note: The valid image file types are: BMP, CALS, GIF, JFIF, PICT, CALS, RAS, TIFF, or TPIC. (Note: File type is optional, as Forms 5 will attempt to deduce it from the source image file. To optimize performance, however, you should specify the file type.)

ecatz wrote:

> Hi!
>
> Can anyone tell me how I can read a bmp file from the local drive and store
> it in an Oracle table in PL/SQL?
>
> Thanks
>
> ECatz

--
Tim McConechy
Database Administrator/Programmer Analyst
WestCoast Interchange Enterprises
Phone:(250) 472-4331
Fax:(250) 721-6497
Email: tmcconec_at_wie.com
http://www.wie.com
Received on Mon Mar 16 1998 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US