DBA Data[Home] [Help]

APPS.BEN_DM_INPUT_FILE_PKG dependencies on UTL_FILE

Line 116: l_file_handle utl_file.file_type;

112: p_delimiter in varchar2 default ';'
113: ) is
114:
115: l_proc varchar2(255) := g_package||'read_file';
116: l_file_handle utl_file.file_type;
117: l_max_ext number := 32767;
118: l_line_text varchar2(32767);
119: l_line_count number := 0;
120: l_group_order number;

Line 177: l_file_handle := utl_file.fopen(l_dir_name,l_file_name,'r',l_max_ext);

173:
174: --
175: -- get the file handle
176: --
177: l_file_handle := utl_file.fopen(l_dir_name,l_file_name,'r',l_max_ext);
178:
179: --
180: -- fetch records from the file
181: --

Line 186: utl_file.get_line(l_file_handle,l_line_text);

182: loop
183: --
184: begin
185: --
186: utl_file.get_line(l_file_handle,l_line_text);
187: l_line_count := l_line_count +1;
188: l_fields := split_line(l_line_text,p_delimiter,5);
189:
190: l_inp_rec(l_line_count).source_bg := rtrim(ltrim(l_fields(1)));

Line 232: utl_file.fclose(l_file_handle);

228: exit;
229: end;
230: end loop;
231: --
232: utl_file.fclose(l_file_handle);
233: --
234: for i in 1..l_inp_rec.count
235: loop
236:

Line 437: when utl_file.invalid_path then

433: end loop;
434:
435: hr_utility.set_location('Leaving '||l_proc,5);
436: exception
437: when utl_file.invalid_path then
438: rollback;
439: fnd_message.set_name('BEN', 'BEN_91874_EXT_DRCTRY_ERR'); --9999
440: fnd_file.put_line(fnd_file.log, fnd_message.get);
441: if utl_file.is_open(l_file_handle) then

Line 441: if utl_file.is_open(l_file_handle) then

437: when utl_file.invalid_path then
438: rollback;
439: fnd_message.set_name('BEN', 'BEN_91874_EXT_DRCTRY_ERR'); --9999
440: fnd_file.put_line(fnd_file.log, fnd_message.get);
441: if utl_file.is_open(l_file_handle) then
442: utl_file.fclose(l_file_handle);
443: end if;
444: fnd_message.raise_error;
445: --

Line 442: utl_file.fclose(l_file_handle);

438: rollback;
439: fnd_message.set_name('BEN', 'BEN_91874_EXT_DRCTRY_ERR'); --9999
440: fnd_file.put_line(fnd_file.log, fnd_message.get);
441: if utl_file.is_open(l_file_handle) then
442: utl_file.fclose(l_file_handle);
443: end if;
444: fnd_message.raise_error;
445: --
446: when utl_file.invalid_mode then

Line 446: when utl_file.invalid_mode then

442: utl_file.fclose(l_file_handle);
443: end if;
444: fnd_message.raise_error;
445: --
446: when utl_file.invalid_mode then
447: rollback;
448: fnd_message.set_name('BEN', 'BEN_92249_UTL_INVLD_MODE');
449: fnd_file.put_line(fnd_file.log, fnd_message.get);
450: if utl_file.is_open(l_file_handle) then

Line 450: if utl_file.is_open(l_file_handle) then

446: when utl_file.invalid_mode then
447: rollback;
448: fnd_message.set_name('BEN', 'BEN_92249_UTL_INVLD_MODE');
449: fnd_file.put_line(fnd_file.log, fnd_message.get);
450: if utl_file.is_open(l_file_handle) then
451: utl_file.fclose(l_file_handle);
452: end if;
453: fnd_message.raise_error;
454: --

Line 451: utl_file.fclose(l_file_handle);

447: rollback;
448: fnd_message.set_name('BEN', 'BEN_92249_UTL_INVLD_MODE');
449: fnd_file.put_line(fnd_file.log, fnd_message.get);
450: if utl_file.is_open(l_file_handle) then
451: utl_file.fclose(l_file_handle);
452: end if;
453: fnd_message.raise_error;
454: --
455: when utl_file.invalid_filehandle then

Line 455: when utl_file.invalid_filehandle then

451: utl_file.fclose(l_file_handle);
452: end if;
453: fnd_message.raise_error;
454: --
455: when utl_file.invalid_filehandle then
456: rollback;
457: fnd_message.set_name('BEN', 'BEN_92250_UTL_INVLD_FILEHANDLE');
458: fnd_file.put_line(fnd_file.log, fnd_message.get);
459: if utl_file.is_open(l_file_handle) then

Line 459: if utl_file.is_open(l_file_handle) then

455: when utl_file.invalid_filehandle then
456: rollback;
457: fnd_message.set_name('BEN', 'BEN_92250_UTL_INVLD_FILEHANDLE');
458: fnd_file.put_line(fnd_file.log, fnd_message.get);
459: if utl_file.is_open(l_file_handle) then
460: utl_file.fclose(l_file_handle);
461: end if;
462: fnd_message.raise_error;
463: --

Line 460: utl_file.fclose(l_file_handle);

456: rollback;
457: fnd_message.set_name('BEN', 'BEN_92250_UTL_INVLD_FILEHANDLE');
458: fnd_file.put_line(fnd_file.log, fnd_message.get);
459: if utl_file.is_open(l_file_handle) then
460: utl_file.fclose(l_file_handle);
461: end if;
462: fnd_message.raise_error;
463: --
464: when utl_file.invalid_operation then

Line 464: when utl_file.invalid_operation then

460: utl_file.fclose(l_file_handle);
461: end if;
462: fnd_message.raise_error;
463: --
464: when utl_file.invalid_operation then
465: rollback;
466: fnd_message.set_name('BEN', 'BEN_92251_UTL_INVLD_OPER');
467: fnd_file.put_line(fnd_file.log, fnd_message.get);
468: if utl_file.is_open(l_file_handle) then

Line 468: if utl_file.is_open(l_file_handle) then

464: when utl_file.invalid_operation then
465: rollback;
466: fnd_message.set_name('BEN', 'BEN_92251_UTL_INVLD_OPER');
467: fnd_file.put_line(fnd_file.log, fnd_message.get);
468: if utl_file.is_open(l_file_handle) then
469: utl_file.fclose(l_file_handle);
470: end if;
471: fnd_message.raise_error;
472: --

Line 469: utl_file.fclose(l_file_handle);

465: rollback;
466: fnd_message.set_name('BEN', 'BEN_92251_UTL_INVLD_OPER');
467: fnd_file.put_line(fnd_file.log, fnd_message.get);
468: if utl_file.is_open(l_file_handle) then
469: utl_file.fclose(l_file_handle);
470: end if;
471: fnd_message.raise_error;
472: --
473: when utl_file.read_error then

Line 473: when utl_file.read_error then

469: utl_file.fclose(l_file_handle);
470: end if;
471: fnd_message.raise_error;
472: --
473: when utl_file.read_error then
474: rollback;
475: fnd_message.set_name('BEN', 'BEN_92252_UTL_READ_ERROR');
476: fnd_file.put_line(fnd_file.log, fnd_message.get);
477: if utl_file.is_open(l_file_handle) then

Line 477: if utl_file.is_open(l_file_handle) then

473: when utl_file.read_error then
474: rollback;
475: fnd_message.set_name('BEN', 'BEN_92252_UTL_READ_ERROR');
476: fnd_file.put_line(fnd_file.log, fnd_message.get);
477: if utl_file.is_open(l_file_handle) then
478: utl_file.fclose(l_file_handle);
479: end if;
480: fnd_message.raise_error;
481: --

Line 478: utl_file.fclose(l_file_handle);

474: rollback;
475: fnd_message.set_name('BEN', 'BEN_92252_UTL_READ_ERROR');
476: fnd_file.put_line(fnd_file.log, fnd_message.get);
477: if utl_file.is_open(l_file_handle) then
478: utl_file.fclose(l_file_handle);
479: end if;
480: fnd_message.raise_error;
481: --
482: when utl_file.internal_error then

Line 482: when utl_file.internal_error then

478: utl_file.fclose(l_file_handle);
479: end if;
480: fnd_message.raise_error;
481: --
482: when utl_file.internal_error then
483: rollback;
484: fnd_message.set_name('BEN', 'BEN_92253_UTL_INTRNL_ERROR');
485: fnd_file.put_line(fnd_file.log, fnd_message.get);
486: if utl_file.is_open(l_file_handle) then

Line 486: if utl_file.is_open(l_file_handle) then

482: when utl_file.internal_error then
483: rollback;
484: fnd_message.set_name('BEN', 'BEN_92253_UTL_INTRNL_ERROR');
485: fnd_file.put_line(fnd_file.log, fnd_message.get);
486: if utl_file.is_open(l_file_handle) then
487: utl_file.fclose(l_file_handle);
488: end if;
489: fnd_message.raise_error;
490: --

Line 487: utl_file.fclose(l_file_handle);

483: rollback;
484: fnd_message.set_name('BEN', 'BEN_92253_UTL_INTRNL_ERROR');
485: fnd_file.put_line(fnd_file.log, fnd_message.get);
486: if utl_file.is_open(l_file_handle) then
487: utl_file.fclose(l_file_handle);
488: end if;
489: fnd_message.raise_error;
490: --
491: when utl_file.invalid_maxlinesize then

Line 491: when utl_file.invalid_maxlinesize then

487: utl_file.fclose(l_file_handle);
488: end if;
489: fnd_message.raise_error;
490: --
491: when utl_file.invalid_maxlinesize then
492: rollback;
493: fnd_message.set_name ('BEN' ,'BEN_92492_UTL_LINESIZE_ERROR');
494: fnd_file.put_line(fnd_file.log , fnd_message.get );
495: if utl_file.is_open(l_file_handle) then

Line 495: if utl_file.is_open(l_file_handle) then

491: when utl_file.invalid_maxlinesize then
492: rollback;
493: fnd_message.set_name ('BEN' ,'BEN_92492_UTL_LINESIZE_ERROR');
494: fnd_file.put_line(fnd_file.log , fnd_message.get );
495: if utl_file.is_open(l_file_handle) then
496: utl_file.fclose(l_file_handle);
497: end if;
498: fnd_message.raise_error ;
499: --

Line 496: utl_file.fclose(l_file_handle);

492: rollback;
493: fnd_message.set_name ('BEN' ,'BEN_92492_UTL_LINESIZE_ERROR');
494: fnd_file.put_line(fnd_file.log , fnd_message.get );
495: if utl_file.is_open(l_file_handle) then
496: utl_file.fclose(l_file_handle);
497: end if;
498: fnd_message.raise_error ;
499: --
500: when g_missing_fields then

Line 503: if utl_file.is_open(l_file_handle) then

499: --
500: when g_missing_fields then
501: rollback;
502: fnd_file.put_line(fnd_file.log , 'One ore more fields missing in this Record: '||substr(l_line_text,1,80));
503: if utl_file.is_open(l_file_handle) then
504: utl_file.fclose(l_file_handle);
505: end if;
506: raise;
507: --

Line 504: utl_file.fclose(l_file_handle);

500: when g_missing_fields then
501: rollback;
502: fnd_file.put_line(fnd_file.log , 'One ore more fields missing in this Record: '||substr(l_line_text,1,80));
503: if utl_file.is_open(l_file_handle) then
504: utl_file.fclose(l_file_handle);
505: end if;
506: raise;
507: --
508: when g_invalid_record then

Line 511: if utl_file.is_open(l_file_handle) then

507: --
508: when g_invalid_record then
509: rollback;
510: fnd_file.put_line(fnd_file.log , 'Invalid fields in this Record: '||substr(l_line_text,1,80));
511: if utl_file.is_open(l_file_handle) then
512: utl_file.fclose(l_file_handle);
513: end if;
514: raise;
515: --

Line 512: utl_file.fclose(l_file_handle);

508: when g_invalid_record then
509: rollback;
510: fnd_file.put_line(fnd_file.log , 'Invalid fields in this Record: '||substr(l_line_text,1,80));
511: if utl_file.is_open(l_file_handle) then
512: utl_file.fclose(l_file_handle);
513: end if;
514: raise;
515: --
516: when others then

Line 518: if utl_file.is_open(l_file_handle) then

514: raise;
515: --
516: when others then
517: rollback;
518: if utl_file.is_open(l_file_handle) then
519: utl_file.fclose(l_file_handle);
520: end if;
521: raise;
522:

Line 519: utl_file.fclose(l_file_handle);

515: --
516: when others then
517: rollback;
518: if utl_file.is_open(l_file_handle) then
519: utl_file.fclose(l_file_handle);
520: end if;
521: raise;
522:
523: end read_file;