Re: edit your init.ora
Date: Sun, 2 Aug 1998 09:28:22 +0200
Message-ID: <6q14dv$7sq$1_at_newton.a2000.nl>
Hmmmm, adding some more exception handling could have told you on which line the error occurred.
As it is a user defined exception, it has to be one of the file operations that fails. As you did not mention that you changed the file init.ora, I guess that Oracle refuses to write to E:\. Init.ora needs one or more lines telling Oracle where it may read from, or write to, explicitly including all subdirectories:
utl_file_dir = E:\ utl_file_dir = E:\temp utl_file_dir = E:\temp\spool
etc. Or,
utl_file_dir = *
to allow Oracle to read from, and write to, any directory the user 'oracle' can access. You need to restart the database when you change inti.ora. The following code can check it on run-time:
create function isValidFileDir( p_FileDir in varchar2 )
return boolean
as
v_Count integer;
begin
select count(*)
into v_Count
from v$parameter
where upper( name ) = 'UTL_FILE_DIR'
and ( value = p_FileDir
or value = '*' );
if v_Count = 0
then
return false;
else
return true;
end if;
end isValidFileDir;
Arjan.
> file_out := UTL_FILE.FOPEN('e:\', 'my_file.txt', 'w');
Received on Sun Aug 02 1998 - 09:28:22 CEST