Monday, October 12, 2009

FND_FILE

An API that contains procedures to write text to log and output files which can be viewed once the Concurrent program get completed in output or log . These procedures can only be used within PL/SQL Procedures which, are concurrent programs.

Internally its uses the oracle supplied database package UTL_FILE

utl_file_dir parameter must be set to include the log and out directories for the applications that will run concurrent requests using FND_FILE
Database owner must have write privileges on those directories
Take a note that FND_FILE supports a maximum buffer line size of 32K for both log and output files.

FND_FILE.PUT - Useful for writing text to a file without a new line character. Multiple calls will concatenate the text. Does not include new line character

FND_FILE.PUT_LINE This is used to write a line of text to a file followed by a new line character

FND_FILE.NEW_LINE FND_FILE.NEW_LINE( which IN NUMBER, LINES IN NATURAL:= 1) Writes line terminators (new line characters) to a file.Eg. FND_FILE.NEW_LINE(FND_FILE.LOG,2)

FND_File.PUT_NAMES This is used to sets temporary log and out file names and directory, which normally used during test and debug phase.

FND_FILE.CLOSE This will closes open files.

This is normally used only during test and debug phase

No comments:

Post a Comment