| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Uploading files using the PL/SQL cartridge
Greetings all...
I am not able to upload files into the database based on part of the example given in the MetaLink site, note #77573.1.
Here are the versions of software being used:
Oracle8i EE 8.1.6.3
OAS 4.0.8.2.3
AIX 4.3.3
Here is the my source:
CREATE OR REPLACE PACKAGE websys.foobar IS
PROCEDURE upload_form ;
PROCEDURE upload_data(file_name IN VARCHAR2) ;
END foobar ;
/
CREATE OR REPLACE PACKAGE BODY websys.foobar AS
PROCEDURE upload_form IS
BEGIN
htp.hr;
htp.header(1, 'File Uploading');
htp.hr;
htp.formopen(CURL=>'foobar.upload_data',
CMETHOD=>'POST',
CENCTYPE=>'multipart/form-data');
htp.tableopen(CBORDER=>'0');
htp.tablerowopen;
htp.tabledata('File:');
htp.tabledata('<INPUT TYPE="FILE" NAME="file_name">');
htp.tablerowclose;
htp.tablerowopen;
htp.tabledata(htf.formsubmit);
htp.tabledata(htf.formreset);
htp.tablerowclose;
htp.tableclose;
htp.formclose;
PROCEDURE upload_data(file_name IN VARCHAR2) IS BEGIN
htp.htmlopen;
htp.headopen;
htp.title('File Uploaded');
htp.headclose;
htp.bodyopen;
htp.header(1, 'Upload Status');
htp.print('Uploaded successfully');
htp.bodyclose;
htp.htmlclose;
I created these objects under WEBSYS, created a public synonym, and made sure our DAD user has execute on the package.
When I attempt to upload a file into the database, the result is simply the 'Uploaded successfully' message, but no record in WEBSYS.OWS_CONTENT. Am I missing something? I thought this was going to be a no-brainer but this has been frustrating me for a full day now.
Thanks in advance,
dan Received on Wed Apr 24 2002 - 13:27:00 CDT
![]() |
![]() |