4:
5: procedure delete_allRiskyInstr
6: is
7: begin
8: delete from iby_irf_risky_instr;
9: commit;
10: end;
11:
12: /*
28: lx_cc_number iby_creditcard.ccnumber%TYPE;
29: lx_return_status VARCHAR2(1);
30: lx_msg_count NUMBER;
31: lx_msg_data VARCHAR2(200);
32: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
33: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
34: l_cc_number iby_creditcard.ccnumber%TYPE;
35: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
36: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
29: lx_return_status VARCHAR2(1);
30: lx_msg_count NUMBER;
31: lx_msg_data VARCHAR2(200);
32: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
33: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
34: l_cc_number iby_creditcard.ccnumber%TYPE;
35: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
36: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
37: begin
31: lx_msg_data VARCHAR2(200);
32: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
33: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
34: l_cc_number iby_creditcard.ccnumber%TYPE;
35: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
36: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
37: begin
38: -- initialize the values.
39: i := 1;
32: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
33: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
34: l_cc_number iby_creditcard.ccnumber%TYPE;
35: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
36: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
37: begin
38: -- initialize the values.
39: i := 1;
40: --dbms_output.put_line('at beginning');
86: (lx_cc_number,FND_API.G_FALSE);
87: l_cc_hash2 := iby_security_pkg.get_hash
88: (lx_cc_number,FND_API.G_TRUE);
89: SELECT COUNT(-1) INTO l_riskinscount
90: FROM iby_irf_risky_instr
91: WHERE payeeid = l_payeeid
92: and instrtype = l_instrtype
93: and cc_number_hash1 = l_cc_hash1
94: and cc_number_hash2 = l_cc_hash2;
93: and cc_number_hash1 = l_cc_hash1
94: and cc_number_hash2 = l_cc_hash2;
95: IF ( l_riskinscount = 0 ) then
96: -- Included hash1 and hash2 values as part of bug#7228388
97: insert into iby_irf_risky_instr
98: (payeeid, instrtype,
99: creditcard_no, object_version_number,
100: last_update_date, last_updated_by,
101: creation_date, created_by, cc_number_hash1,
122: (i_riskyinstr(i).Account_Num,FND_API.G_FALSE);
123: l_account_no_hash2 := iby_security_pkg.get_hash
124: (i_riskyinstr(i).Account_Num,FND_API.G_TRUE);
125: SELECT COUNT(-1) INTO l_riskinscount
126: FROM iby_irf_risky_instr
127: WHERE payeeid = l_payeeid
128: and instrtype = l_instrtype
129: and routing_no = i_riskyinstr(i).Routing_Num
130: and acct_number_hash1 = l_account_no_hash1
130: and acct_number_hash1 = l_account_no_hash1
131: and acct_number_hash2 = l_account_no_hash2;
132:
133: IF ( l_riskinscount = 0 ) then
134: insert into iby_irf_risky_instr
135: (payeeid, instrtype, routing_no,
136: account_no, object_version_number,
137: last_update_date, last_updated_by,
138: creation_date, created_by,acct_number_hash1,
179: lx_cc_number iby_creditcard.ccnumber%TYPE;
180: lx_return_status VARCHAR2(1);
181: lx_msg_count NUMBER;
182: lx_msg_data VARCHAR2(200);
183: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
184: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
185: l_cc_number iby_creditcard.ccnumber%TYPE;
186: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
187: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
180: lx_return_status VARCHAR2(1);
181: lx_msg_count NUMBER;
182: lx_msg_data VARCHAR2(200);
183: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
184: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
185: l_cc_number iby_creditcard.ccnumber%TYPE;
186: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
187: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
188: begin
182: lx_msg_data VARCHAR2(200);
183: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
184: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
185: l_cc_number iby_creditcard.ccnumber%TYPE;
186: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
187: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
188: begin
189: -- initialize the values.
190: i := 1;
183: l_cc_hash1 iby_irf_risky_instr.cc_number_hash1%TYPE;
184: l_cc_hash2 iby_irf_risky_instr.cc_number_hash2%TYPE;
185: l_cc_number iby_creditcard.ccnumber%TYPE;
186: l_account_no_hash1 iby_irf_risky_instr.acct_number_hash1%TYPE;
187: l_account_no_hash2 iby_irf_risky_instr.acct_number_hash2%TYPE;
188: begin
189: -- initialize the values.
190: i := 1;
191:
223: l_cc_hash1 := iby_security_pkg.get_hash
224: (lx_cc_number,FND_API.G_FALSE);
225: l_cc_hash2 := iby_security_pkg.get_hash
226: (lx_cc_number,FND_API.G_TRUE);
227: Delete FROM iby_irf_risky_instr
228: WHERE payeeid = l_payeeid
229: and instrtype = l_instrtype
230: and cc_number_hash1 = l_cc_hash1
231: and cc_number_hash2 = l_cc_hash2;
240: l_account_no_hash1 := iby_security_pkg.get_hash
241: (i_riskyinstr(i).Account_Num,FND_API.G_FALSE);
242: l_account_no_hash2 := iby_security_pkg.get_hash
243: (i_riskyinstr(i).Account_Num,FND_API.G_TRUE);
244: Delete FROM iby_irf_risky_instr
245: WHERE payeeid = l_payeeid
246: and instrtype = l_instrtype
247: and routing_no = i_riskyinstr(i).Routing_Num
248: and acct_number_hash1 = l_account_no_hash1