0

My package code contains fnd_file.put_line for logging purpose. I need to replace this with utl_file.put_line what will be the minimum lines of code I should write. there are 100+ occurences of fnd_file.put_line in my code for 14 procedures. Please explain what is the difference between utl_file and fnd_file? and give me the sample code as well.

My question is:

Can you please explain if the code is on server then how to give the directory location. It will include the server details as well. Please clarify with the example.

PS: I can see this package is part of concurrent programming.Is utl_file in scope?

4

1 に答える 1

1

FND_FILE.PUT_LINE、コンカレント・プログラムを実行すると、出力またはログ・ファイルに文字列が出力されます。

FND_FILE.PUT_LINE(FND_FILE.output, 'message'); -- This will print in Concurrent program output
FND_FILE.PUT_LINE(FND_FILE.log, 'message'); -- This will print in Concurrent program log

UTL_FILE.PUT_LINEpl-sqlで開く必要がある書き込み可能なファイルに文字列を出力します。

UTL_FILE の使用例

v_chr_out_file       UTL_FILE.file_type;
v_chr_out_file :=
            UTL_FILE.fopen (<directory_path>,
                            <file_name>,
                            'W',
                            32767);
UTL_FILE.put_line (v_chr_out_file, 'this will get written in file');
UTL_FILE.fclose (v_chr_out_file);
于 2017-07-25T12:39:18.263 に答える