Link to home
Start Free TrialLog in
Avatar of arwaseem
arwaseem

asked on

Saving Images in Oracle Database useing SQL not Developer 2000

I want to save and then extract an image in Oracle database.
The structure of table i have created is as follow:

ID number(5) Primary Key
Description  Varchar2(256)
Image Long Raw


How I save an image using SQL INSERT Command and How I fetch data from table using SQL SELECT Command?

I don't want to use from defaul and samrt menu.
Thank you.

Avatar of jpkemp
jpkemp

Oracle recommends using LOB (e.g. BLOB) instead of LONG RAW. They have more features and are not limited to 32767 bytes.

SQL doesn't really provide anything for manipulating image data. You get some functionality with PL/SQL (e.g. getting value of LONG RAW / LOB into a PL/SQL variable and vice versa). Usually this is done using Oracle Forms or some other client interface.

Jeff
ASKER CERTIFIED SOLUTION
Avatar of schwertner
schwertner
Flag of Antarctica image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of arwaseem

ASKER

Thanks to all for answer specially to Mr. Schwertner.
In my Quaestion at the bottom I asked that I don't want to use Developer Forms default&Smartbar. Mease I do it through PL/SQL but in forms. I don't use Form's built in functions. First of all I called function on a Button for selecting  image files through "Get_File_name" in a variable; Then I used function "Read_Image_File" This shows Selected Image into :Image object on my Canvas. Then I wrote my own Insertion On "Add Record Button" I wrote triger "When button Pressed"
Insert into <table_name> values(:ID,:DES,:IMAGE);

Error message appears: ORA-01465 invalid hex number

How I remove this error and Why Developers Forms do not support JEPEG format?

Regards
ARwaseem
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial