Tuesday, 13 December 2011

write log file from procedure in oracle

 create directory logfile as 'C:\log_file'; -- must have priv to do this

declare
  SFile utl_file.file_type;
begin
  SFile := utl_file.fopen(logfile ,'sunil','w'); -- w is write. This returns file handle
  utl_file.put(SFile,'Start write th log on log file'); -- note use of file handle vFile
  utl_file.fclose(SFile); -- note use of file handle vFile
end;

0 comments:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Powered by Blogger