0% found this document useful (0 votes)
130 views8 pages

Script Submit Bank Statement Loader

This procedure submits a bank statement loader program and tracks its status and the status of any child programs launched as part of the bank statement import process. It takes parameters for the file name, request ID, file path, load option, mapping template, bank branch number, account number and GL date. It submits the main program request, waits for completion, and checks the status. If the status is normal, it submits any child programs for import and reconciliation, waits for their completion and checks their statuses as well.

Uploaded by

Ceomail001
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
130 views8 pages

Script Submit Bank Statement Loader

This procedure submits a bank statement loader program and tracks its status and the status of any child programs launched as part of the bank statement import process. It takes parameters for the file name, request ID, file path, load option, mapping template, bank branch number, account number and GL date. It submits the main program request, waits for completion, and checks the status. If the status is normal, it submits any child programs for import and reconciliation, waits for their completion and checks their statuses as well.

Uploaded by

Ceomail001
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 8

Sample Script to Submit Bank Statement Loader Program

sample procedure to submit a bank statement loader program and capture the status of programs submitted as part of Bank Statement Import FLOWCHART:

SOURCE CODE:

CREATE OR REPLACE PROCEDURE XXX_REUSB_BANK_SUB_ A! " pi#_file_name IN ARC!AR"$ pin_re%uest_id IN NU#BER$ pi#_file_path IN ARC!AR"$ pi#_load_option IN ARC!AR"$ pi#_map_temp IN ARC!AR"$ pi#_bank_br_num IN ARC!AR"$ pi#_accnt_num IN ARC!AR"$ pi#_gl_date IN ARC!AR" & AS

ln_re%_id NU#BER '( )* ln_user_id NU#BER '( )* ln_resp_id NU#BER '( )* ln_appl_id NU#BER '( )* lb_result BOOLEAN* l#_phase ARC!AR" "+))&* l#_status ARC!AR" "+))&* l#_de#_phase ARC!AR" "+))&* l#_de#_status ARC!AR" "+))&* l#_message ARC!AR" "+))&* l#_sre%uest_status ARC!AR" "+)&* l#_statuscode ARC!AR" ",)&* ln_re%_idNU#BER '( )* l#_submission_error ARC!AR" ",))&* l#_conc_prog ARC!AR" ".))&* l#_load_status ARC!AR" "-)& DE$AULT /SU
BE%IN

ESS/*

DB#S&OUTPUT0put&line "/S1A1E2EN1 3I4ENA2E '/ 55 pi#_file_name&* DB#S&OUTPUT0put&line "/ 666666 S1AR1 73 BANK S1A1E2EN1 47A8ER !R79RA2 S1A1US 666666/&* BE%IN SELECT re%uested_b:$ responsibilit:_application_id$ responsibilit:_id INTO ln_user_id$ ln_appl_id$ ln_resp_id $RO# fnd_concurrent_re%uests '!ERE re%uest_id ( pin_re%uest_id* fnd_global0apps_initiali;e "ln_user_id$ ln_resp_id$ ln_appl_id &* CO##IT* END* BE%IN DB#S&OUTPUT0put&line" /Submit the concurrent progam <Bank Statement 4oader<0/ &* ln_re%_id '( fnd_re%uest0submit_re%uest "application (= / E/$ program (= / ES>448R/$ description (= NULL$ start_time (= NULL$

sub_re%uest argument+ argumentargument. argument? argument, argument@ argumentA argumentB argumentC argument+) argument++ argument+argument+. &*

(= $ALSE$ (= pi#_load_option$ (= pi#_map_temp$ (= pi#_file_name$ (= pi#_file_path$ (= pi#_bank_br_num$ (= pi#_accnt_num$ (= pi#_gl_date$ (= NULL$ (= NULL$ (= NULL$ (= /N/$ (= NULL$ (= NULL

I$ ln_re%_id ( ) T!EN l#_submission_error '( fnd_message0get* DB#S&OUTPUT0put&line " / ERR7R' Bank Statement 4oader not submitted </ 55 l#_submission_error 55 /</ &* l#_load_status '(/3AI4E8/* ELSE CO##IT* DB#S&OUTPUT0put&line " / Re%uest Submitted ' / 55 ln_re%_id &* LOOP lb_result '( fnd_concurrent0Dait_for_re%uest "ln_re%_id$ +)$ +)$ l#_phase$ l#_status$ l#_de#_phase$ l#_de#_status$ l#_message &*

I$ lb_result AND l#_de#_phase ( / 72!4E1E/ T!EN E(IT* END I$* END LOOP* END I$* END* I$ l#_de#_phase ( / 72!4E1E/ T!EN DB#S&OUTPUT0put&line " / Bank Statement 4oader Re%uest 55 l#_de#_status &* I$ l#_de#_status IN "/ERR7R/& T!EN l#_load_status '(/3AI4E8/* END I$*

ompleted Dith status /

$OR cur_re% IN "SELECT a0re%uest_id$ a0logfile_name$ a0outfile_name$ a0concurrent_program_id$ b0user_concurrent_program_name conc_prog $RO# fnd_concurrent_re%uests a$ fnd_concurrent_programs_tl b '!ERE a0parent_re%uest_id ( ln_re%_id AND a0concurrent_program_id ( b0concurrent_program_id AND b0LAN%UA%E ( /US/ ORDER B) a0re%uest_id& LOOP DB#S&OUTPUT0put&line " / / 55 cur_re%0conc_prog 55 / E= RE>UES1 SUB2I11E8 / 55 cur_re%0re%uest_id &* LOOP lb_result '( fnd_concurrent0Dait_for_re%uest "cur_re%0re%uest_id$ +)$ +)$ l#_phase$

l#_status$ l#_de#_phase$ l#_de#_status$ l#_message &* I$ lb_result T!EN I$ l#_de#_phase ( / 72!4E1E/ T!EN DB#S&OUTPUT0put&line " / / 55 cur_re%0conc_prog 55 / has completed successfull:/ &* E(IT* END I$* END I$* END LOOP* I$ UPPER "l#_de#_status& IN "/ERR7R/$ /FARNIN9/& T!EN DB#S&OUTPUT0put&line " / / 55 cur_re%0conc_prog 55 / has completed Dith status / 55 UPPER "l#_de#_status& &* l#_load_status '(/3AI4E8/* ELSI$ UPPER "l#_de#_status& IN "/N7R2A4/& AND cur_re%0conc_prog ( /4oad Bank Statement 8ata/ T!EN $OR cur_re%_in IN "SELECT a0re%uest_id$ a0logfile_name$ a0outfile_name$ a0concurrent_program_id$ b0user_concurrent_program_name conc_prog $RO# fnd_concurrent_re%uests a$ fnd_concurrent_programs_tl b '!ERE a0parent_re%uest_id ( cur_re%0re%uest_id AND a0concurrent_program_id ( b0concurrent_program_id AND b0LAN%UA%E ( /US/ ORDER B) a0re%uest_id& LOOP DB#S&OUTPUT0put&line " / / 55 cur_re%_in0conc_prog

55 / E= RE>UES1 SUB2I11E8 / 55 cur_re%_in0re%uest_id &* LOOP lb_result '( fnd_concurrent0Dait_for_re%uest "cur_re%_in0re%uest_id$ +)$ +)$ l#_phase$ l#_status$ l#_de#_phase$ l#_de#_status$ l#_message &* I$ lb_result T!EN I$ l#_de#_phase ( / 72!4E1E/ T!EN DB#S&OUTPUT0put&line " / / 55 cur_re%_in0conc_prog 55 / has completed Dith status / 55 UPPER "l#_de#_status& &* E(IT* END I$* END I$* END LOOP* I$ UPPER "l#_de#_status& IN "/ERR7R/$ /FARNIN9/& AND cur_re%_in0conc_prog LI*E /Bank Statement ImportGAutoReconciliation/ T!EN l#_load_status '(/3AI4E8/* ELSI$ UPPER "l#_de#_status& IN "/N7R2A4/& AND cur_re%_in0conc_prog LI*E /Bank Statement ImportGAutoReconciliation/ T!EN BE%IN SELECT a0re%uest_id$ b0user_concurrent_program_name conc_prog

INTO ln_re%_id-$ l#_conc_prog $RO# fnd_concurrent_re%uests a$ fnd_concurrent_programs_tl b '!ERE a0parent_re%uest_id ( cur_re%_in0re%uest_id AND a0concurrent_program_id ( b0concurrent_program_id AND b0LAN%UA%E ( /US/* E(CEPTION '!EN N7_8A1A_37UN8 T!EN DB#S&OUTPUT0put&line " / AutoReconcilation EHecution report not called for'/ 55 cur_re%_in0re%uest_id &* '!EN 71IERS T!EN DB#S&OUTPUT0put&line " / AutoReconcilation EHecution report not called for'/ 55 cur_re%_in0re%uest_id &* END* DB#S&OUTPUT0put&line " / / 55 l#_conc_prog 55 / E= RE>UES1 SUB2I11E8 / 55 ln_re%_id&* LOOP lb_result '( fnd_concurrent0Dait_for_re%uest "ln_re%_id-$ +)$ +)$ l#_phase$ l#_status$ l#_de#_phase$ l#_de#_status$ l#_message &* I$ lb_result T!EN I$ l#_de#_phase ( / 72!4E1E/

T!EN DB#S&OUTPUT0put&line " / / 55 l#_conc_prog 55 / has completed Dith status / 55 UPPER "l#_de#_status& &* E(IT* END I$* END I$* END LOOP* END I$* END LOOP* END I$* END LOOP* END I$*

E(CEPTION '!EN 71IERS T!EN DB#S&OUTPUT0put&line "/ / 55 /71IERS EX E!1I7N/ 55 S+LERR# "S+LCODE&&* END XXX_REUSB_BANK_SUB_ A!*

You might also like