DBA Data[Home] [Help]

APPS.FND_FILE dependencies on UTL_FILE

Line 5: F_LOG utl_file.file_type;

1: package body FND_FILE as
2: /* $Header: AFCPPIOB.pls 120.4 2006/05/24 05:34:03 anittala ship $ */
3:
4:
5: F_LOG utl_file.file_type;
6: F_OUT utl_file.file_type;
7:
8: LOG_FNAME varchar2(255);
9: OUT_FNAME varchar2(255);

Line 6: F_OUT utl_file.file_type;

2: /* $Header: AFCPPIOB.pls 120.4 2006/05/24 05:34:03 anittala ship $ */
3:
4:
5: F_LOG utl_file.file_type;
6: F_OUT utl_file.file_type;
7:
8: LOG_FNAME varchar2(255);
9: OUT_FNAME varchar2(255);
10: TEMP_DIR varchar2(255);

Line 78: ** utl_file.invalid_path - file location or name was invalid

74: /*
75: ** OPEN_FILES - open or create temporary log and output files
76: **
77: ** EXCEPTIONS
78: ** utl_file.invalid_path - file location or name was invalid
79: ** utl_file.invalid_mode - the open_mode string was invalid
80: ** utl_file.invalid_operation - file could not be opened as requested
81: ** utl_file.invalid_maxlinesize - specified max line size is too large or
82: ** too small

Line 79: ** utl_file.invalid_mode - the open_mode string was invalid

75: ** OPEN_FILES - open or create temporary log and output files
76: **
77: ** EXCEPTIONS
78: ** utl_file.invalid_path - file location or name was invalid
79: ** utl_file.invalid_mode - the open_mode string was invalid
80: ** utl_file.invalid_operation - file could not be opened as requested
81: ** utl_file.invalid_maxlinesize - specified max line size is too large or
82: ** too small
83: */

Line 80: ** utl_file.invalid_operation - file could not be opened as requested

76: **
77: ** EXCEPTIONS
78: ** utl_file.invalid_path - file location or name was invalid
79: ** utl_file.invalid_mode - the open_mode string was invalid
80: ** utl_file.invalid_operation - file could not be opened as requested
81: ** utl_file.invalid_maxlinesize - specified max line size is too large or
82: ** too small
83: */
84:

Line 81: ** utl_file.invalid_maxlinesize - specified max line size is too large or

77: ** EXCEPTIONS
78: ** utl_file.invalid_path - file location or name was invalid
79: ** utl_file.invalid_mode - the open_mode string was invalid
80: ** utl_file.invalid_operation - file could not be opened as requested
81: ** utl_file.invalid_maxlinesize - specified max line size is too large or
82: ** too small
83: */
84:
85: procedure OPEN_FILES is

Line 98: F_OUT := utl_file.fopen(TEMP_DIR, OUT_FNAME, 'w');

94: OUT_FNAME := GET_TEMP_NAME('OUT');
95: temp_file := OUT_FNAME;
96:
97: -- Open and close file to use the workaround for bug
98: F_OUT := utl_file.fopen(TEMP_DIR, OUT_FNAME, 'w');
99:
100: BEGIN
101: utl_file.fclose(F_OUT);
102: EXCEPTION

Line 101: utl_file.fclose(F_OUT);

97: -- Open and close file to use the workaround for bug
98: F_OUT := utl_file.fopen(TEMP_DIR, OUT_FNAME, 'w');
99:
100: BEGIN
101: utl_file.fclose(F_OUT);
102: EXCEPTION
103: when others then
104: NULL;
105: END;

Line 107: F_OUT := utl_file.fopen(TEMP_DIR, OUT_FNAME, 'w', MAX_LINESIZE);

103: when others then
104: NULL;
105: END;
106:
107: F_OUT := utl_file.fopen(TEMP_DIR, OUT_FNAME, 'w', MAX_LINESIZE);
108: OUT_OPEN := TRUE;
109: end if;
110:
111: if LOG_OPEN = FALSE then

Line 117: F_LOG := utl_file.fopen(TEMP_DIR, LOG_FNAME, 'w');

113: */
114: LOG_FNAME := GET_TEMP_NAME('LOG');
115: temp_file := LOG_FNAME;
116: -- Open and close file to use the workaround for bug
117: F_LOG := utl_file.fopen(TEMP_DIR, LOG_FNAME, 'w');
118:
119: BEGIN
120: utl_file.fclose(F_LOG);
121: EXCEPTION

Line 120: utl_file.fclose(F_LOG);

116: -- Open and close file to use the workaround for bug
117: F_LOG := utl_file.fopen(TEMP_DIR, LOG_FNAME, 'w');
118:
119: BEGIN
120: utl_file.fclose(F_LOG);
121: EXCEPTION
122: when others then
123: NULL;
124: END;

Line 126: F_LOG := utl_file.fopen(TEMP_DIR, LOG_FNAME, 'w', MAX_LINESIZE);

122: when others then
123: NULL;
124: END;
125:
126: F_LOG := utl_file.fopen(TEMP_DIR, LOG_FNAME, 'w', MAX_LINESIZE);
127: LOG_OPEN := TRUE;
128: end if;
129:
130: exception

Line 131: when UTL_FILE.INVALID_PATH then

127: LOG_OPEN := TRUE;
128: end if;
129:
130: exception
131: when UTL_FILE.INVALID_PATH then
132: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
133: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
134: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
135: user_error := substrb(fnd_message.get, 1, 255);

Line 143: when UTL_FILE.INVALID_MODE then

139: if (FND_LOG.LEVEL_ERROR >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
140: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.open_files.invalid_path', FALSE);
141: end if;
142: raise_application_error(-20100, user_error);
143: when UTL_FILE.INVALID_MODE then
144: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
145: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
146: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
147: user_error := substrb(fnd_message.get, 1, 255);

Line 156: when UTL_FILE.INVALID_OPERATION then

152: if (FND_LOG.LEVEL_ERROR >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
153: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.open_files.invalid_mode', FALSE);
154: end if;
155: raise_application_error(-20100, user_error);
156: when UTL_FILE.INVALID_OPERATION then
157: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
158: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
159: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
160: user_error := substrb(fnd_message.get, 1, 255);

Line 169: when UTL_FILE.INVALID_MAXLINESIZE then

165: if (FND_LOG.LEVEL_ERROR >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
166: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.open_files.invalid_operatn', FALSE);
167: end if;
168: raise_application_error(-20100, user_error);
169: when UTL_FILE.INVALID_MAXLINESIZE then
170: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
171: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
172: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
173: user_error := substrb(fnd_message.get, 1, 255);

Line 194: utl_file.fclose(F_LOG);

190: procedure CLOSE is
191: BEGIN
192:
193: BEGIN
194: utl_file.fclose(F_LOG);
195: EXCEPTION
196: when others then
197: NULL;
198: END;

Line 201: utl_file.fclose(F_OUT);

197: NULL;
198: END;
199:
200: BEGIN
201: utl_file.fclose(F_OUT);
202: EXCEPTION
203: when others then
204: NULL;
205: END;

Line 273: -- use first entry of utl_file_dir as the TEMP_DIR

269:
270: if LOG_FNAME is null AND
271: OUT_FNAME is null AND
272: TEMP_DIR is null then
273: -- use first entry of utl_file_dir as the TEMP_DIR
274: -- if there is no entry then do not even construct file names
275: select translate(ltrim(value),',',' ')
276: into TEMP_UTL
277: from v$parameter

Line 278: where name = 'utl_file_dir';

274: -- if there is no entry then do not even construct file names
275: select translate(ltrim(value),',',' ')
276: into TEMP_UTL
277: from v$parameter
278: where name = 'utl_file_dir';
279:
280: if (instr(TEMP_UTL,' ') > 0 and TEMP_UTL is not null) then
281: select substrb(TEMP_UTL, 1, instr(TEMP_UTL,' ') - 1)
282: into TEMP_DIR

Line 346: utl_file.put(F_LOG, BUFF);

342:
343: if WHICH = FND_FILE.LOG then
344: temp_file := LOG_FNAME;
345: if ( WTYPE = 'PUT' ) then
346: utl_file.put(F_LOG, BUFF);
347: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
348: fnd_log.string(FND_LOG.LEVEL_EVENT,
349: 'fnd.plsql.FND_FILE.WRITE_BUFF.put', BUFF);
350: end if;

Line 352: utl_file.put_line(F_LOG, BUFF);

348: fnd_log.string(FND_LOG.LEVEL_EVENT,
349: 'fnd.plsql.FND_FILE.WRITE_BUFF.put', BUFF);
350: end if;
351: elsif (WTYPE = 'PUT_LINE' ) then
352: utl_file.put_line(F_LOG, BUFF);
353: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
354: fnd_log.string(FND_LOG.LEVEL_EVENT,
355: 'fnd.plsql.FND_FILE.WRITE_BUFF.put_line', BUFF);
356: end if;

Line 358: utl_file.new_line(F_LOG, to_number(BUFF) );

354: fnd_log.string(FND_LOG.LEVEL_EVENT,
355: 'fnd.plsql.FND_FILE.WRITE_BUFF.put_line', BUFF);
356: end if;
357: elsif (WTYPE = 'NEW_LINE') then
358: utl_file.new_line(F_LOG, to_number(BUFF) );
359: end if;
360: utl_file.fflush(F_LOG);
361: elsif WHICH = FND_FILE.OUTPUT then
362: temp_file := OUT_FNAME;

Line 360: utl_file.fflush(F_LOG);

356: end if;
357: elsif (WTYPE = 'NEW_LINE') then
358: utl_file.new_line(F_LOG, to_number(BUFF) );
359: end if;
360: utl_file.fflush(F_LOG);
361: elsif WHICH = FND_FILE.OUTPUT then
362: temp_file := OUT_FNAME;
363: if ( WTYPE = 'PUT' ) then
364: utl_file.put(F_OUT, BUFF);

Line 364: utl_file.put(F_OUT, BUFF);

360: utl_file.fflush(F_LOG);
361: elsif WHICH = FND_FILE.OUTPUT then
362: temp_file := OUT_FNAME;
363: if ( WTYPE = 'PUT' ) then
364: utl_file.put(F_OUT, BUFF);
365: elsif (WTYPE = 'PUT_LINE' ) then
366: utl_file.put_line(F_OUT, BUFF);
367: elsif (WTYPE = 'NEW_LINE') then
368: utl_file.new_line(F_OUT, to_number(BUFF) );

Line 366: utl_file.put_line(F_OUT, BUFF);

362: temp_file := OUT_FNAME;
363: if ( WTYPE = 'PUT' ) then
364: utl_file.put(F_OUT, BUFF);
365: elsif (WTYPE = 'PUT_LINE' ) then
366: utl_file.put_line(F_OUT, BUFF);
367: elsif (WTYPE = 'NEW_LINE') then
368: utl_file.new_line(F_OUT, to_number(BUFF) );
369: end if;
370: utl_file.fflush(F_OUT);

Line 368: utl_file.new_line(F_OUT, to_number(BUFF) );

364: utl_file.put(F_OUT, BUFF);
365: elsif (WTYPE = 'PUT_LINE' ) then
366: utl_file.put_line(F_OUT, BUFF);
367: elsif (WTYPE = 'NEW_LINE') then
368: utl_file.new_line(F_OUT, to_number(BUFF) );
369: end if;
370: utl_file.fflush(F_OUT);
371: end if;
372: end if;

Line 370: utl_file.fflush(F_OUT);

366: utl_file.put_line(F_OUT, BUFF);
367: elsif (WTYPE = 'NEW_LINE') then
368: utl_file.new_line(F_OUT, to_number(BUFF) );
369: end if;
370: utl_file.fflush(F_OUT);
371: end if;
372: end if;
373:
374: exception

Line 375: when UTL_FILE.INVALID_FILEHANDLE then

371: end if;
372: end if;
373:
374: exception
375: when UTL_FILE.INVALID_FILEHANDLE then
376: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
377: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
378: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
379: user_error := substrb(fnd_message.get, 1, 255);

Line 388: when UTL_FILE.INVALID_OPERATION then

384: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.write_buff.invalid_handle', FALSE);
385: end if;
386: raise_application_error(-20100, user_error);
387:
388: when UTL_FILE.INVALID_OPERATION then
389: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
390: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
391: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
392: user_error := substrb(fnd_message.get, 1, 255);

Line 402: when UTL_FILE.WRITE_ERROR then

398: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.write_buff.invalid_operatn', FALSE);
399: end if;
400: raise_application_error(-20100, user_error);
401:
402: when UTL_FILE.WRITE_ERROR then
403: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
404: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
405: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
406: user_error := substrb(fnd_message.get, 1, 255);

Line 428: ** utl_file.invalid_path (*) - file location or name was invalid

424: ** IN
425: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
426: ** BUFF - Text to write
427: ** EXCEPTIONS
428: ** utl_file.invalid_path (*) - file location or name was invalid
429: ** utl_file.invalid_mode (*) - the open_mode string was invalid
430: ** utl_file.invalid_filehandle - file handle is invalid
431: ** utl_file.invalid_operation - file is not open for writing/appending
432: ** utl_file.write_error - OS error occured during write operation

Line 429: ** utl_file.invalid_mode (*) - the open_mode string was invalid

425: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
426: ** BUFF - Text to write
427: ** EXCEPTIONS
428: ** utl_file.invalid_path (*) - file location or name was invalid
429: ** utl_file.invalid_mode (*) - the open_mode string was invalid
430: ** utl_file.invalid_filehandle - file handle is invalid
431: ** utl_file.invalid_operation - file is not open for writing/appending
432: ** utl_file.write_error - OS error occured during write operation
433: */

Line 430: ** utl_file.invalid_filehandle - file handle is invalid

426: ** BUFF - Text to write
427: ** EXCEPTIONS
428: ** utl_file.invalid_path (*) - file location or name was invalid
429: ** utl_file.invalid_mode (*) - the open_mode string was invalid
430: ** utl_file.invalid_filehandle - file handle is invalid
431: ** utl_file.invalid_operation - file is not open for writing/appending
432: ** utl_file.write_error - OS error occured during write operation
433: */
434: procedure PUT(WHICH in number, BUFF in varchar2) is

Line 431: ** utl_file.invalid_operation - file is not open for writing/appending

427: ** EXCEPTIONS
428: ** utl_file.invalid_path (*) - file location or name was invalid
429: ** utl_file.invalid_mode (*) - the open_mode string was invalid
430: ** utl_file.invalid_filehandle - file handle is invalid
431: ** utl_file.invalid_operation - file is not open for writing/appending
432: ** utl_file.write_error - OS error occured during write operation
433: */
434: procedure PUT(WHICH in number, BUFF in varchar2) is
435: temp_file varchar2(255); -- used for messages

Line 432: ** utl_file.write_error - OS error occured during write operation

428: ** utl_file.invalid_path (*) - file location or name was invalid
429: ** utl_file.invalid_mode (*) - the open_mode string was invalid
430: ** utl_file.invalid_filehandle - file handle is invalid
431: ** utl_file.invalid_operation - file is not open for writing/appending
432: ** utl_file.write_error - OS error occured during write operation
433: */
434: procedure PUT(WHICH in number, BUFF in varchar2) is
435: temp_file varchar2(255); -- used for messages
436: user_error varchar2(255); -- to store translated file_error

Line 440: utl_file.put(F_LOG, BUFF);

436: user_error varchar2(255); -- to store translated file_error
437: begin
438: if WHICH = FND_FILE.LOG then
439: temp_file := LOG_FNAME;
440: utl_file.put(F_LOG, BUFF);
441: utl_file.fflush(F_LOG);
442: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
443: fnd_log.string(FND_LOG.LEVEL_EVENT,
444: 'fnd.plsql.FND_FILE.WRITE_BUFF.put', BUFF);

Line 441: utl_file.fflush(F_LOG);

437: begin
438: if WHICH = FND_FILE.LOG then
439: temp_file := LOG_FNAME;
440: utl_file.put(F_LOG, BUFF);
441: utl_file.fflush(F_LOG);
442: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
443: fnd_log.string(FND_LOG.LEVEL_EVENT,
444: 'fnd.plsql.FND_FILE.WRITE_BUFF.put', BUFF);
445: end if;

Line 448: utl_file.put(F_OUT, BUFF);

444: 'fnd.plsql.FND_FILE.WRITE_BUFF.put', BUFF);
445: end if;
446: elsif WHICH = FND_FILE.OUTPUT then
447: temp_file := OUT_FNAME;
448: utl_file.put(F_OUT, BUFF);
449: utl_file.fflush(F_OUT);
450: end if;
451:
452: exception

Line 449: utl_file.fflush(F_OUT);

445: end if;
446: elsif WHICH = FND_FILE.OUTPUT then
447: temp_file := OUT_FNAME;
448: utl_file.put(F_OUT, BUFF);
449: utl_file.fflush(F_OUT);
450: end if;
451:
452: exception
453: when UTL_FILE.INVALID_FILEHANDLE then

Line 453: when UTL_FILE.INVALID_FILEHANDLE then

449: utl_file.fflush(F_OUT);
450: end if;
451:
452: exception
453: when UTL_FILE.INVALID_FILEHANDLE then
454: -- first time this could be file not open case
455: -- try opening temp files and write
456: WRITE_BUFF(WHICH, 'PUT', BUFF);
457:

Line 458: when UTL_FILE.INVALID_OPERATION then

454: -- first time this could be file not open case
455: -- try opening temp files and write
456: WRITE_BUFF(WHICH, 'PUT', BUFF);
457:
458: when UTL_FILE.INVALID_OPERATION then
459: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
460: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
461: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
462: user_error := substrb(fnd_message.get, 1, 255);

Line 472: when UTL_FILE.WRITE_ERROR then

468: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.put.invalid_operatn', FALSE);
469: end if;
470: raise_application_error(-20100, user_error);
471:
472: when UTL_FILE.WRITE_ERROR then
473: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
474: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
475: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
476: user_error := substrb(fnd_message.get, 1, 255);

Line 498: ** utl_file.invalid_path - file location or name was invalid

494: ** IN
495: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
496: ** BUFF - Text to write
497: ** EXCEPTIONS
498: ** utl_file.invalid_path - file location or name was invalid
499: ** utl_file.invalid_mode - the open_mode string was invalid
500: ** utl_file.invalid_filehandle - file handle is invalid
501: ** utl_file.invalid_operation - file is not open for writing/appending
502: ** utl_file.write_error - OS error occured during write operation

Line 499: ** utl_file.invalid_mode - the open_mode string was invalid

495: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
496: ** BUFF - Text to write
497: ** EXCEPTIONS
498: ** utl_file.invalid_path - file location or name was invalid
499: ** utl_file.invalid_mode - the open_mode string was invalid
500: ** utl_file.invalid_filehandle - file handle is invalid
501: ** utl_file.invalid_operation - file is not open for writing/appending
502: ** utl_file.write_error - OS error occured during write operation
503: */

Line 500: ** utl_file.invalid_filehandle - file handle is invalid

496: ** BUFF - Text to write
497: ** EXCEPTIONS
498: ** utl_file.invalid_path - file location or name was invalid
499: ** utl_file.invalid_mode - the open_mode string was invalid
500: ** utl_file.invalid_filehandle - file handle is invalid
501: ** utl_file.invalid_operation - file is not open for writing/appending
502: ** utl_file.write_error - OS error occured during write operation
503: */
504: procedure PUT_LINE(WHICH in number, BUFF in varchar2) is

Line 501: ** utl_file.invalid_operation - file is not open for writing/appending

497: ** EXCEPTIONS
498: ** utl_file.invalid_path - file location or name was invalid
499: ** utl_file.invalid_mode - the open_mode string was invalid
500: ** utl_file.invalid_filehandle - file handle is invalid
501: ** utl_file.invalid_operation - file is not open for writing/appending
502: ** utl_file.write_error - OS error occured during write operation
503: */
504: procedure PUT_LINE(WHICH in number, BUFF in varchar2) is
505: temp_file varchar2(255); -- used for messages

Line 502: ** utl_file.write_error - OS error occured during write operation

498: ** utl_file.invalid_path - file location or name was invalid
499: ** utl_file.invalid_mode - the open_mode string was invalid
500: ** utl_file.invalid_filehandle - file handle is invalid
501: ** utl_file.invalid_operation - file is not open for writing/appending
502: ** utl_file.write_error - OS error occured during write operation
503: */
504: procedure PUT_LINE(WHICH in number, BUFF in varchar2) is
505: temp_file varchar2(255); -- used for messages
506: user_error varchar2(255); -- to store translated file_error

Line 510: utl_file.put_line(F_LOG, BUFF);

506: user_error varchar2(255); -- to store translated file_error
507: begin
508: if WHICH = FND_FILE.LOG then
509: temp_file := LOG_FNAME;
510: utl_file.put_line(F_LOG, BUFF);
511: utl_file.fflush(F_LOG);
512: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
513: fnd_log.string(FND_LOG.LEVEL_EVENT,
514: 'fnd.plsql.FND_FILE.PUT_LINE', BUFF);

Line 511: utl_file.fflush(F_LOG);

507: begin
508: if WHICH = FND_FILE.LOG then
509: temp_file := LOG_FNAME;
510: utl_file.put_line(F_LOG, BUFF);
511: utl_file.fflush(F_LOG);
512: if (FND_LOG.LEVEL_EVENT >= FND_LOG.G_CURRENT_RUNTIME_LEVEL) then
513: fnd_log.string(FND_LOG.LEVEL_EVENT,
514: 'fnd.plsql.FND_FILE.PUT_LINE', BUFF);
515: end if;

Line 518: utl_file.put_line(F_OUT, BUFF);

514: 'fnd.plsql.FND_FILE.PUT_LINE', BUFF);
515: end if;
516: elsif WHICH = FND_FILE.OUTPUT then
517: temp_file := OUT_FNAME;
518: utl_file.put_line(F_OUT, BUFF);
519: utl_file.fflush(F_OUT);
520: end if;
521:
522: exception

Line 519: utl_file.fflush(F_OUT);

515: end if;
516: elsif WHICH = FND_FILE.OUTPUT then
517: temp_file := OUT_FNAME;
518: utl_file.put_line(F_OUT, BUFF);
519: utl_file.fflush(F_OUT);
520: end if;
521:
522: exception
523: when UTL_FILE.INVALID_FILEHANDLE then

Line 523: when UTL_FILE.INVALID_FILEHANDLE then

519: utl_file.fflush(F_OUT);
520: end if;
521:
522: exception
523: when UTL_FILE.INVALID_FILEHANDLE then
524: -- first time this could be file not open case
525: -- try opening temp files and write
526: WRITE_BUFF(WHICH, 'PUT_LINE', BUFF);
527:

Line 528: when UTL_FILE.INVALID_OPERATION then

524: -- first time this could be file not open case
525: -- try opening temp files and write
526: WRITE_BUFF(WHICH, 'PUT_LINE', BUFF);
527:
528: when UTL_FILE.INVALID_OPERATION then
529: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
530: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
531: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
532: user_error := substrb(fnd_message.get, 1, 255);

Line 542: when UTL_FILE.WRITE_ERROR then

538: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.put_line.invalid_operatn', FALSE);
539: end if;
540: raise_application_error(-20100, user_error);
541:
542: when UTL_FILE.WRITE_ERROR then
543: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
544: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
545: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
546: user_error := substrb(fnd_message.get, 1, 255);

Line 568: ** utl_file.invalid_path - file location or name was invalid

564: ** IN
565: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
566: ** LINES - Number of line terminators to write
567: ** EXCEPTIONS
568: ** utl_file.invalid_path - file location or name was invalid
569: ** utl_file.invalid_mode - the open_mode string was invalid
570: ** utl_file.invalid_filehandle - file handle is invalid
571: ** utl_file.invalid_operation - file is not open for writing/appending
572: ** utl_file.write_error - OS error occured during write operation

Line 569: ** utl_file.invalid_mode - the open_mode string was invalid

565: ** WHICH - Log or output file? Either FND_FILE.LOG or FND_FILE.OUTPUT
566: ** LINES - Number of line terminators to write
567: ** EXCEPTIONS
568: ** utl_file.invalid_path - file location or name was invalid
569: ** utl_file.invalid_mode - the open_mode string was invalid
570: ** utl_file.invalid_filehandle - file handle is invalid
571: ** utl_file.invalid_operation - file is not open for writing/appending
572: ** utl_file.write_error - OS error occured during write operation
573: */

Line 570: ** utl_file.invalid_filehandle - file handle is invalid

566: ** LINES - Number of line terminators to write
567: ** EXCEPTIONS
568: ** utl_file.invalid_path - file location or name was invalid
569: ** utl_file.invalid_mode - the open_mode string was invalid
570: ** utl_file.invalid_filehandle - file handle is invalid
571: ** utl_file.invalid_operation - file is not open for writing/appending
572: ** utl_file.write_error - OS error occured during write operation
573: */
574: procedure NEW_LINE(WHICH in number, LINES in natural := 1) is

Line 571: ** utl_file.invalid_operation - file is not open for writing/appending

567: ** EXCEPTIONS
568: ** utl_file.invalid_path - file location or name was invalid
569: ** utl_file.invalid_mode - the open_mode string was invalid
570: ** utl_file.invalid_filehandle - file handle is invalid
571: ** utl_file.invalid_operation - file is not open for writing/appending
572: ** utl_file.write_error - OS error occured during write operation
573: */
574: procedure NEW_LINE(WHICH in number, LINES in natural := 1) is
575: temp_file varchar2(255); -- used for messages

Line 572: ** utl_file.write_error - OS error occured during write operation

568: ** utl_file.invalid_path - file location or name was invalid
569: ** utl_file.invalid_mode - the open_mode string was invalid
570: ** utl_file.invalid_filehandle - file handle is invalid
571: ** utl_file.invalid_operation - file is not open for writing/appending
572: ** utl_file.write_error - OS error occured during write operation
573: */
574: procedure NEW_LINE(WHICH in number, LINES in natural := 1) is
575: temp_file varchar2(255); -- used for messages
576: user_error varchar2(255); -- to store translated file_error

Line 580: utl_file.new_line(F_LOG, LINES);

576: user_error varchar2(255); -- to store translated file_error
577: begin
578: if WHICH = FND_FILE.LOG then
579: temp_file := LOG_FNAME;
580: utl_file.new_line(F_LOG, LINES);
581: utl_file.fflush(F_LOG);
582: elsif WHICH = FND_FILE.OUTPUT then
583: temp_file := OUT_FNAME;
584: utl_file.new_line(F_OUT, LINES);

Line 581: utl_file.fflush(F_LOG);

577: begin
578: if WHICH = FND_FILE.LOG then
579: temp_file := LOG_FNAME;
580: utl_file.new_line(F_LOG, LINES);
581: utl_file.fflush(F_LOG);
582: elsif WHICH = FND_FILE.OUTPUT then
583: temp_file := OUT_FNAME;
584: utl_file.new_line(F_OUT, LINES);
585: utl_file.fflush(F_OUT);

Line 584: utl_file.new_line(F_OUT, LINES);

580: utl_file.new_line(F_LOG, LINES);
581: utl_file.fflush(F_LOG);
582: elsif WHICH = FND_FILE.OUTPUT then
583: temp_file := OUT_FNAME;
584: utl_file.new_line(F_OUT, LINES);
585: utl_file.fflush(F_OUT);
586: end if;
587:
588: exception

Line 585: utl_file.fflush(F_OUT);

581: utl_file.fflush(F_LOG);
582: elsif WHICH = FND_FILE.OUTPUT then
583: temp_file := OUT_FNAME;
584: utl_file.new_line(F_OUT, LINES);
585: utl_file.fflush(F_OUT);
586: end if;
587:
588: exception
589: when UTL_FILE.INVALID_FILEHANDLE then

Line 589: when UTL_FILE.INVALID_FILEHANDLE then

585: utl_file.fflush(F_OUT);
586: end if;
587:
588: exception
589: when UTL_FILE.INVALID_FILEHANDLE then
590: -- first time this could be file not open case
591: -- try opening temp files and write
592: WRITE_BUFF(WHICH, 'NEW_LINE', to_char(LINES));
593:

Line 594: when UTL_FILE.INVALID_OPERATION then

590: -- first time this could be file not open case
591: -- try opening temp files and write
592: WRITE_BUFF(WHICH, 'NEW_LINE', to_char(LINES));
593:
594: when UTL_FILE.INVALID_OPERATION then
595: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
596: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
597: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
598:

Line 609: when UTL_FILE.WRITE_ERROR then

605: fnd_log.message(FND_LOG.LEVEL_ERROR, 'fnd.plsql.fnd_file.newLine.invalid_operatn', FALSE);
606: end if;
607: raise_application_error(-20100, user_error);
608:
609: when UTL_FILE.WRITE_ERROR then
610: fnd_message.set_name('FND', 'CONC-FILE_ERROR');
611: fnd_message.set_token('TEMP_FILE', temp_file, FALSE);
612: fnd_message.set_token('TEMP_DIR', TEMP_DIR, FALSE);
613: user_error := substrb(fnd_message.get, 1, 255);