Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Can someone help me add logging to my stored procedure?
>>>>> "Craig" == Craig Burtenshaw <crb_at_amsa.gov.au> writes:
Craig> "Dafella" <dafella007_at_yahoo.com> wrote in message
Craig> news:203d44c5.0303261345.2f9cfb47_at_posting.google.com...
>> I have the following code that depends on spooling to create some
>> sort of log. But if I try and capture my records and keys I get a
>> buffer overflow. How do I write my key, phone and userfield out
>> to a plain ole text file?
Craig> Using utl_file and also for your errors increase the Craig> SERVEROUTPUT size to 10000000.
Unless its changed in 9i, the maximum serveroutput size is 1Mb e.g 1000000
I don't think dbms_output is any good for a logging mechanism. Apart from the limited buffer size, the data is not written until after your plsql has completed and if it crashes for some reason, you don't get anything.
I find using either a table and autonomous transactions works well or use utl_file.
A few people have stated utl_file is a security hole, however so far, nobody has shown me a convincing argument where util_file is correctly configured (e.g. not using the '*' in utl_file_dir etc) and the OS is correctly configured where util_file is a security hole.
Tim
-- Tim Cross The e-mail address on this message is FALSE (obviously!). My real e-mail is to a company in Australia called rapttech and my login is tcross - if you really need to send mail, you should be able to work it out!Received on Fri Mar 28 2003 - 03:15:44 CST
![]() |
![]() |