Blob File Upload and Download
[EE] Instead to setting up WOW as a File Server there may be cases where you would actually like to store files inside of the database rather than on the Application Server. WOW can upload any file into a blob field of a database or you can serve documents off of WOW from a database blob field. Some examples include storing/serving contracts, forms, pictures, PDFs and Word documents that are associated with records in the database. Any type of binary file can be served or uploaded into the blob field using WOW.
In this example, the WOWSAMPLES.EMPLOYEEFILES table will be used.
The table used to store blob entries and other files including attachments must contain at least the required fields marked with a * below (and have the specified usage ID if needed).
The fields and their possible values are as follows:
ID – A unique ID assigned to each blob file. *
EMPLOYEENUM – This field is used to match files to the employee table.
FILENAME – The file name. * Usage Id: -200
DESCRIPTION – A description of the file.
MIME_TYPE – Type of file specification. * Usage Id: -190
FILE_SIZE – Size of the file being stored in the database. * Usage Id: -210
UPLOAD_TMSP - The timestamp of when the file was uploaded.
LAST_DOWNLOAD_TMSP - The timestamp of when the file was last downloaded.
FILE_BLOB – Blob field that stores the file. *
Any file can be used to store the blob field but it must at least have the required fields and usage IDs set from the files table above.