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 -> Oracle interMedia - upload web page problem

Oracle interMedia - upload web page problem

From: acelestial <acelestial_at_twp.cwellington.on.ca>
Date: Wed, 3 Apr 2002 10:18:08 -0500
Message-ID: <Q2Fq8.62665$iU5.443108481@radon.golden.net>


My table includes a BLOB column where I use an upload web page to populate the fields particularly the BLOB column. This is so as for the end-users to be able to upload files in the table. I got the procedure and html from Oracle's online beta training. See procedure/html below.

The problem is on the procedure to upload the files. It sometimes work specially with documents without images, sometimes not at all. It's intermittent. There's no problem in adding records (BLOB) manually in the table.

These are the errors that I'm getting:
Oracle interMedia Web Agent
An error occurred processing your MEDIAGET or MEDIAPUT request

ORA-01400: cannot insert NULL into ("WEBADMIN"."DOCS"."DOC_ID")
ORA-06512: at "WEBADMIN.PUT_DOCS", line 12
ORA-06512: at line 1

It states that I'm inserting NULL in DOC_ID column but in the upload web page, I have entered a value other than NULL in this column.

Hope anybody could point me to the right direction in regards to what we want to accomplish. Has anyone ever done this before and has the same problem?

Thanks for the help.

Regards,
Arman

Here's the Procedure:
PROCEDURE Put_Docs
(

    IN_docID IN VARCHAR2,
    IN_itemID IN VARCHAR2,
    ord_content_type IN VARCHAR2,
    ord_content_blob OUT blob
)
AS

BEGIN INSERT INTO DOCS (doc_id,item_id,mimetype,docfile) VALUES (in_docid,in_itemid,ord_content_type,EMPTY_BLOB()) RETURN docfile INTO ord_content_blob;

END;


Here's the HTML:
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>

   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
   <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
   <title>Add a document to an item Record</title>

</head>
<body>

&nbsp;
<br>&nbsp;
<p><form action="http://servername/intermedia/myDBAgent/mediaput/PUT_DOCS"
      method="post"
      enctype="multipart/form-data">

<p><font size=+4>Load a document for an item</font>
<br><!-- The Document ID is used as the Primary key --><b>Document ID:</b>
<br><input type="text" name="in_docid" size=10>
<br><!-- The Item ID is used as the Item key --><b>Item ID:</b>
<br><input type="text" name="in_itemid" size=10>
<br><b>Item Document:</b>
<br><!-- We use file input to add the image --><input type="file"
name="ord_content" size=50>
<br>&nbsp;
<p><input type="Submit" value="Store Document"><input type="reset"
value="Clear Data">
<br></form>

</body>
</html>
Received on Wed Apr 03 2002 - 09:18:08 CST

Original text of this message

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