This content has been marked as final. Show 5 replies
this can be done, a lob doesn't have to be stored in the database, but can be an external file referenced by an external lob reference, but, whats the difference! The lobs are still consuming space on your database server, whether they are externally referenced files or lobs in the database as part of the data file (.dbf).
the general approach to download files from the filesystem using Apex would be to
1. Create a directory in your file system the database has access to. Important: The OS user the database is running under must have read and write permissions to this directory.
2. Create a logical directory object with SQL plus (or whatever) pointing to the physical location and grant read,write to the schema users who want to use it.
3. Assuming you have some files in the directory, you can use bfilename to reference a file. The general approach would be
l_filename := bfilename('<Your directory object>','<filename>');
-- Set HTTP header with mime type etc.
To store uploaded files to your filesystem via Apex you can use the APEX_APPLICATION_FILES dictionary view to do this. Besides some general information about file size, type etc. you have a column BLOB_CONTENT containing the file as blob. All you have to do is to write the blob to disk using UTL_FILE, most likely using the procedure put_raw. You will find more information and examples in the database documentation. Once you have written the file to disk you can delete the relating record from APEX_APPLICATION_FILES.
hi forum friends,
I download from apex apex plugin website .and followed the guidelines..i could upload the pdf files to OS file system(as Oracle Directory)..but i could not do the DML operation even download option via apex plugin tools.
Please visit my query in previous days......
Not Download file from oracle directory at the end i propose DB level file upload and download in apex. becoz we want 2 million pdf pages dealing from apex application also security. Thanx Ram