The following lines contain the word 'select', 'insert', 'update' or 'delete':
** unfortunately, we can't delete files on the server
** deleting will have to be done with a cron job or something
**
** IN
** filetype - file to close log/out
** RETURN
** BOOLEAN - was file closed successfully ?
** EXCEPTIONS
** invalid_filehandle - not a valid file handle
** write_error - OS error occured during write operation
*/
function CLOSE_FILE(filetype in varchar2) return boolean is
begin
if (filetype = 'LOG') then
if (utl_file.is_open(LOG)) then
utl_file.fclose(LOG);