Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: DBMS_LOB question - LOADFROMFILE problem
David wrote:
> Hi, I have been using DBMS_LOB to load files from a native file system
> into an Oracle 8.1.7.0.0 database. An excerpt of the code I have used
> is below (the line numbers are for reference only):
>
> 1. DBMS_LOB.FILEOPEN(l_BFILE);
> 2. DBMS_LOB.LOADFROMFILE(l_CLOB,l_BFILE,500);
> 3. DBMS_LOB.CLOSEFILE(l_BFILE);
>
> An exception on line 2. was thrown and the file was never closed, that
> is line 3 never executed. Now when I try to delete the file in the
> underlying file system is says (Win2K) "Cannot delete xxxx.txt: There
> has been a sharing violation".
>
> I've fixed the problem in the code so that when exceptions are raised,
> the file will be closed from now on. But I am not sure now how to get
> Oracle to close the file it holding onto (other than taking down the
> database/server which isn't an option).
>
> Hmmm. Ideas anyone?
>
> Thank you
> David
Reboot the machine. That is the universal solution for all Microsoft product problems: This one too.
-- Daniel Morgan http://www.outreach.washington.edu/extinfo/certprog/oad/oad_crs.asp damorgan_at_x.washington.edu (replace 'x' with a 'u' to reply)Received on Thu May 29 2003 - 10:20:15 CDT