Home » Developer & Programmer » Forms » Insert SQL--- LONG datatype.. (Oracle 9i)
Insert SQL--- LONG datatype.. [message #382743] Sat, 24 January 2009 00:20 Go to next message
sanjeev.sharda
Messages: 14
Registered: December 2008
Location: Ludhiana
Junior Member

hello friends.. i hv create a table itemdb_images in Oracle 9i which desc.. blow.. i store images for items in this table... i want to copy a record to new item using select.. i m getting the error ..... illegal use of LONG datatype..

i use this sql
INSERT INTO itemdb_IMAGEs(doc_pk,item_code,doc_scanned_copy,file_name,file_extension,USER_INSERT,DATE_INSERT,USER_EDIT,DATE_EDIT)
SELECT itemdb_images_pk.NEXTVAL,6,doc_scanned_copy,file_name,file_extension,'ADMIN', SYSDATE,'Admin', SYSDATE
FROM itemdb_images
WHERE ITEM_CODE=5;


item_code=5 is my old item which saved alreadyin table and now i m copy into new item_code=6


Please help me how can i insert data...



desc itemdb_images
DOC_PK NOT NULL NUMBER(15)
ITEM_CODE NOT NULL NUMBER(10)
DOC_SCANNED_COPY NOT NULL LONG RAW
FILE_NAME NOT NULL VARCHAR2(50)
FILE_EXTENSION NOT NULL VARCHAR2(4)
USER_INSERT NOT NULL VARCHAR2(10)
DATE_INSERT NOT NULL DATE
USER_EDIT NOT NULL VARCHAR2(10)
DATE_EDIT NOT NULL DATE
Re: Insert SQL--- LONG datatype.. [message #382745 is a reply to message #382743] Sat, 24 January 2009 00:28 Go to previous messageGo to next message
BlackSwan
Messages: 25049
Registered: January 2009
Location: SoCal
Senior Member
You have table & provided us no DDL for it.
You have data & provided us no DML for test data.

You need to help us by following the Posting Guidelines as stated below.
http://www.orafaq.com/forum/t/88153/0/
So we can help you.

You have not shown us via CUT & PASTE what you actually did or how Oracle responded.

You have not provided any expected output.
Re: Insert SQL--- LONG datatype.. [message #382747 is a reply to message #382743] Sat, 24 January 2009 01:05 Go to previous messageGo to next message
Michel Cadot
Messages: 64145
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
More than 10 years that Oracle says: don't use LONG use CLOB.

Regards
Michel
Re: Insert SQL--- LONG datatype.. [message #382754 is a reply to message #382747] Sat, 24 January 2009 04:50 Go to previous messageGo to next message
sanjeev.sharda
Messages: 14
Registered: December 2008
Location: Ludhiana
Junior Member

i was try clob i can save the image in database but i failed to display image in form6i execute query ... help me what i do ?
Re: Insert SQL--- LONG datatype.. [message #382771 is a reply to message #382754] Sat, 24 January 2009 09:08 Go to previous message
Michel Cadot
Messages: 64145
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I don't know but what I know is that this has been asked many times and you will surely get the answer in Forms forum.

Regards
Michel
Previous Topic: Master-Detail-Detail Relationship
Next Topic: Generating and Reading BarCode info.
Goto Forum:
  


Current Time: Fri Dec 09 11:33:20 CST 2016

Total time taken to generate the page: 0.15584 seconds