DBA Data[Home] [Help]

APPS.PQH_RBC_UTILITY dependencies on BEN_COPY_ENTITY_RESULTS

Line 14: cursor c21 is select distinct information13 from ben_copy_entity_results

10: and criteria_short_code is not null
11: and a.eligy_prfl_id = b.eligy_prfl_id;
12:
13:
14: cursor c21 is select distinct information13 from ben_copy_entity_results
15: where copy_entity_txn_id = p_copy_entity_txn_id
16: and table_alias = 'RBC_CRIT'; -- also consider 'DELETE' status rows
17:
18: l_short_code varchar2(100);

Line 26: select information1 into l_rate_matrix_id from ben_copy_entity_results

22: begin
23: l_status := 'NO';
24: l_temp_found := 'NO';
25:
26: select information1 into l_rate_matrix_id from ben_copy_entity_results
27: where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'PLN';
28:
29: open c11(l_rate_matrix_id);
30: loop

Line 87: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';

83: begin
84: hr_utility.set_location('going for deleting matrix values row',100);
85: /*
86: if p_mode = 'CREATE' then
87: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';
88: else
89: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';
90: end if;
91: */ -- dont use this because each row has its characteristics to revert back independent of pmode

Line 89: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';

85: /*
86: if p_mode = 'CREATE' then
87: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';
88: else
89: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';
90: end if;
91: */ -- dont use this because each row has its characteristics to revert back independent of pmode
92:
93: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation = 'CREATE';

Line 93: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation = 'CREATE';

89: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV';
90: end if;
91: */ -- dont use this because each row has its characteristics to revert back independent of pmode
92:
93: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation = 'CREATE';
94: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation in ('UPDATE','COPIED');
95:
96: exception
97: when others then

Line 94: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation in ('UPDATE','COPIED');

90: end if;
91: */ -- dont use this because each row has its characteristics to revert back independent of pmode
92:
93: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation = 'CREATE';
94: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMV' and dml_operation in ('UPDATE','COPIED');
95:
96: exception
97: when others then
98: hr_utility.set_location('issues in deleting matrix values row',100);

Line 110: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';

106: begin
107: hr_utility.set_location('going for deleting matrix rates row',100);
108: /*
109: if p_mode = 'CREATE' then
110: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
111: else
112: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
113: end if;
114: */

Line 112: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';

108: /*
109: if p_mode = 'CREATE' then
110: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
111: else
112: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
113: end if;
114: */
115: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation = 'CREATE';
116: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation in ('UPDATE','COPIED');

Line 115: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation = 'CREATE';

111: else
112: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
113: end if;
114: */
115: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation = 'CREATE';
116: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation in ('UPDATE','COPIED');
117:
118:
119: exception

Line 116: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation in ('UPDATE','COPIED');

112: update ben_copy_entity_results set dml_operation = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR';
113: end if;
114: */
115: delete from ben_copy_entity_results where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation = 'CREATE';
116: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where INFORMATION161 = p_rate_matrix_node_id and copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMR' and dml_operation in ('UPDATE','COPIED');
117:
118:
119: exception
120: when others then

Line 137: cursor c1 is select information1 from ben_copy_entity_results where

133: ) is
134: l_rate_matrix_node_id number;
135:
136: -- p_mode in UPDATE or CREATE
137: cursor c1 is select information1 from ben_copy_entity_results where
138: Copy_entity_txn_id = p_copy_entity_txn_id and
139: Information160 = p_level and
140: information13 = p_short_code and
141: Information261 = p_pl_id and

Line 147: delete from ben_copy_entity_results where

143: begin
144: hr_utility.set_location('going for deleting matrix nodes row',100);
145:
146: -- USE THIS IF YOU ARE NOT CALLING VOROW.REMOVE IN AM
147: delete from ben_copy_entity_results where
148: Copy_entity_txn_id = p_copy_entity_txn_id and
149: Information160 = p_level and
150: information13 = p_short_code and
151: Information261 = p_pl_id and

Line 155: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where

151: Information261 = p_pl_id and
152: TABLE_ALIAS = 'RBC_CRIT' and
153: dml_operation = 'CREATE';
154:
155: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where
156: Copy_entity_txn_id = p_copy_entity_txn_id and
157: Information160 = p_level and
158: information13 = p_short_code and
159: Information261 = p_pl_id and

Line 177: delete from ben_copy_entity_results where

173: end if;
174: close c1;
175:
176: --DELETE RMN CURRENT ROW AFTER DELETING CHILD
177: delete from ben_copy_entity_results where
178: Copy_entity_txn_id = p_copy_entity_txn_id and
179: Information160 = p_level and
180: information13 = p_short_code and
181: Information261 = p_pl_id and

Line 185: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where

181: Information261 = p_pl_id and
182: TABLE_ALIAS = 'RMN' and
183: dml_operation = 'CREATE';
184:
185: update ben_copy_entity_results set dml_operation = 'DELETE',datetrack_mode = 'DELETE' where
186: Copy_entity_txn_id = p_copy_entity_txn_id and
187: Information160 = p_level and
188: information13 = p_short_code and
189: Information261 = p_pl_id and

Line 203: To check if there are criteria values present in rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RMN' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.

199:
200:
201:
202: /*
203: To check if there are criteria values present in rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RMN' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.
204: To check if there are criteria attached to rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.
205: */
206:
207:

Line 204: To check if there are criteria attached to rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.

200:
201:
202: /*
203: To check if there are criteria values present in rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RMN' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.
204: To check if there are criteria attached to rate matrix, check if there are any rows in ben_copy_entity_results with table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE' for the current copy_entity_txn_id.
205: */
206:
207:
208: function allow_hgrid_reorder(p_copy_entity_txn_id in number) return varchar2 IS

Line 212: cursor c1 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMN' and dml_operation <> 'DELETE' and information160 <> 1;

208: function allow_hgrid_reorder(p_copy_entity_txn_id in number) return varchar2 IS
209: l_temp varchar2(1);
210: l_max number;
211:
212: cursor c1 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMN' and dml_operation <> 'DELETE' and information160 <> 1;
213: cursor c2 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';
214: BEGIN
215:
216: /* INSTEAD OF C2 WE CAN USE THIS

Line 213: cursor c2 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';

209: l_temp varchar2(1);
210: l_max number;
211:
212: cursor c1 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RMN' and dml_operation <> 'DELETE' and information160 <> 1;
213: cursor c2 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';
214: BEGIN
215:
216: /* INSTEAD OF C2 WE CAN USE THIS
217: select max(nvl(information160,1)) into l_max from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';

Line 217: select max(nvl(information160,1)) into l_max from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';

213: cursor c2 is select null from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';
214: BEGIN
215:
216: /* INSTEAD OF C2 WE CAN USE THIS
217: select max(nvl(information160,1)) into l_max from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';
218: if l_max = 1 then
219: return 'DisallowOrder';
220: end if;
221: */

Line 330: ben_copy_entity_results_api.create_copy_entity_results(

326: (p_table_alias => 'EGL',
327: p_table_route_id => l_egl_tr_id,
328: p_table_name => l_egl_tr_name);
329:
330: ben_copy_entity_results_api.create_copy_entity_results(
331: p_effective_date => p_effective_date
332: ,p_copy_entity_txn_id => p_copy_entity_txn_id
333: ,p_result_type_cd => 'DISPLAY'
334: ,p_table_name => l_egl_tr_name

Line 423: ben_copy_entity_results_api.create_copy_entity_results (

419: end if;
420:
421: -- copy every thing similar to copy_egl_row but keep our business_group_id instead
422:
423: ben_copy_entity_results_api.create_copy_entity_results (
424: p_copy_entity_result_id => l_egl_cer_id,
425: p_copy_entity_txn_id => p_copy_entity_txn_id,
426: p_result_type_cd => 'DISPLAY',
427: p_number_of_copies => 1,

Line 532: ben_copy_entity_results_api.create_copy_entity_results (

528: hr_utility.set_location('value set name is'||l_flex_value_set_name,10);
529: else
530: hr_utility.set_location('value set is not used',10);
531: end if;
532: ben_copy_entity_results_api.create_copy_entity_results (
533: p_copy_entity_result_id => l_egl_cer_id,
534: p_copy_entity_txn_id => p_copy_entity_txn_id,
535: p_result_type_cd => 'DISPLAY',
536: p_number_of_copies => 1,

Line 917: cursor c1 is select * from ben_copy_entity_results

913:
914: procedure stage_to_criteria(p_copy_entity_txn_id in number,
915: p_effective_date in date,
916: p_eligy_criteria_id out nocopy number) is
917: cursor c1 is select * from ben_copy_entity_results
918: where table_alias = 'EGL'
919: and copy_entity_txn_id = p_copy_entity_txn_id;
920: l_eligy_criteria_id number;
921: l_eligy_ovn number;

Line 1089: cursor c2 is select information1 from ben_copy_entity_results where

1085: l_rate_matrix_rate_id2 number;
1086: l_ret_vlaue varchar2(3);
1087: cursor c1 is select rate_matrix_rate_id from pqh_rate_matrix_rates_f
1088: where criteria_rate_defn_id = p_criteria_rate_defn_id;
1089: cursor c2 is select information1 from ben_copy_entity_results where
1090: information1 = p_criteria_rate_defn_id and table_alias = 'RCR';
1091: BEGIN
1092: open c1;
1093: fetch c1 into l_rate_matrix_rate_id;

Line 1227: from ben_copy_entity_results

1223: p_removed_dep_crd out nocopy varchar2) is
1224: --
1225: Cursor csr_exist_crd(p_crd_id in number) is
1226: Select 'x'
1227: from ben_copy_entity_results
1228: Where copy_entity_txn_id = p_copy_entity_txn_id
1229: AND table_alias = 'RMR'
1230: AND information162 = p_crd_id
1231: and dml_operation <> 'DELETE'

Line 1236: from ben_copy_entity_results

1232: and information1 is not null;
1233: --
1234: Cursor csr_rm is
1235: Select information1
1236: from ben_copy_entity_results
1237: Where copy_entity_txn_id = p_copy_entity_txn_id
1238: AND table_alias = 'PLN';
1239: --
1240: Cursor csr_ref_crd(p_rate_matrix_id in number) is

Line 1242: from ben_copy_entity_results

1238: AND table_alias = 'PLN';
1239: --
1240: Cursor csr_ref_crd(p_rate_matrix_id in number) is
1241: Select copy_entity_result_id, information1 , nvl(information5,'name') crd_name,information160
1242: from ben_copy_entity_results
1243: Where table_alias = 'RCR'
1244: and copy_entity_txn_id = p_copy_entity_txn_id
1245: and (information1 = p_criteria_rate_defn_id OR
1246: information1 in (select criteria_rate_defn_id

Line 1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;

1250: )
1251: );
1252: --
1253: l_dummy varchar2(1);
1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1257: l_curr_order_number ben_copy_entity_results.information160%type;
1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;

Line 1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;

1251: );
1252: --
1253: l_dummy varchar2(1);
1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1257: l_curr_order_number ben_copy_entity_results.information160%type;
1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;
1259: --

Line 1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;

1252: --
1253: l_dummy varchar2(1);
1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1257: l_curr_order_number ben_copy_entity_results.information160%type;
1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;
1259: --
1260: Begin

Line 1257: l_curr_order_number ben_copy_entity_results.information160%type;

1253: l_dummy varchar2(1);
1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1257: l_curr_order_number ben_copy_entity_results.information160%type;
1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;
1259: --
1260: Begin
1261: --

Line 1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;

1254: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1255: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1256: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1257: l_curr_order_number ben_copy_entity_results.information160%type;
1258: l_curr_rate_matrix_id ben_copy_entity_results.information1%type;
1259: --
1260: Begin
1261: --
1262: hr_utility.set_location('Entering',5);

Line 1310: Delete from ben_copy_entity_results

1306: If csr_exist_crd%notfound then
1307: --
1308: -- Criteria Rate definition was added to rate matrix as a part of current txn.
1309: --
1310: Delete from ben_copy_entity_results
1311: Where copy_entity_txn_id = p_copy_entity_txn_id
1312: AND table_alias = 'RMR'
1313: AND information162 = l_criteria_rate_defn_id
1314: and dml_operation <> 'DELETE';

Line 1322: Update ben_copy_entity_results

1318: -- Criteria Rate definition was previously added to rate matrix.Hence rates
1319: -- must be deleted from the master table. Hence mark it for deletion in
1320: -- staging area.
1321: --
1322: Update ben_copy_entity_results
1323: set dml_operation = 'DELETE'
1324: Where copy_entity_txn_id = p_copy_entity_txn_id
1325: AND table_alias = 'RMR'
1326: AND information162 = l_criteria_rate_defn_id

Line 1335: Delete from ben_copy_entity_results

1331: --
1332: -- Delete RCR row.
1333: --
1334: hr_utility.set_location('Deleting:'||to_char(l_copy_entity_result_id),15);
1335: Delete from ben_copy_entity_results
1336: Where copy_entity_txn_id = p_copy_entity_txn_id
1337: and table_alias = 'RCR'
1338: and copy_entity_result_id = l_copy_entity_result_id;
1339: --

Line 1343: Update ben_copy_entity_results

1339: --
1340: -- Adjust order number for remanining RCR rows.
1341: --
1342: /**
1343: Update ben_copy_entity_results
1344: set information160 = (information160 - 1)
1345: Where copy_entity_txn_id = p_copy_entity_txn_id
1346: and table_alias = 'RCR'
1347: and information160 > l_curr_order_number;

Line 1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;

1357: ) is
1358: --
1359: --
1360: l_dummy varchar2(1);
1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1364: l_curr_order_number ben_copy_entity_results.information160%type;
1365: l_new_order_number ben_copy_entity_results.information160%type := 0;

Line 1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;

1358: --
1359: --
1360: l_dummy varchar2(1);
1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1364: l_curr_order_number ben_copy_entity_results.information160%type;
1365: l_new_order_number ben_copy_entity_results.information160%type := 0;
1366: l_parent pqh_criteria_rate_defn.criteria_rate_defn_id%type;

Line 1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;

1359: --
1360: l_dummy varchar2(1);
1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1364: l_curr_order_number ben_copy_entity_results.information160%type;
1365: l_new_order_number ben_copy_entity_results.information160%type := 0;
1366: l_parent pqh_criteria_rate_defn.criteria_rate_defn_id%type;
1367: l_curr_rate_matrix_id ben_pl_f.pl_id%type;

Line 1364: l_curr_order_number ben_copy_entity_results.information160%type;

1360: l_dummy varchar2(1);
1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1364: l_curr_order_number ben_copy_entity_results.information160%type;
1365: l_new_order_number ben_copy_entity_results.information160%type := 0;
1366: l_parent pqh_criteria_rate_defn.criteria_rate_defn_id%type;
1367: l_curr_rate_matrix_id ben_pl_f.pl_id%type;
1368: --

Line 1365: l_new_order_number ben_copy_entity_results.information160%type := 0;

1361: l_copy_entity_result_id ben_copy_entity_results.copy_entity_result_id%type;
1362: l_criteria_rate_defn_id ben_copy_entity_results.information1%type;
1363: l_criteria_rate_defn_name ben_copy_entity_results.information5%type;
1364: l_curr_order_number ben_copy_entity_results.information160%type;
1365: l_new_order_number ben_copy_entity_results.information160%type := 0;
1366: l_parent pqh_criteria_rate_defn.criteria_rate_defn_id%type;
1367: l_curr_rate_matrix_id ben_pl_f.pl_id%type;
1368: --
1369: Cursor csr_ref_crd is

Line 1371: from ben_copy_entity_results

1367: l_curr_rate_matrix_id ben_pl_f.pl_id%type;
1368: --
1369: Cursor csr_ref_crd is
1370: Select copy_entity_result_id, information1 , nvl(information5,'name') crd_name,information160
1371: from ben_copy_entity_results
1372: Where table_alias = 'RCR'
1373: and copy_entity_txn_id = p_copy_entity_txn_id
1374: order by information160;
1375: --

Line 1378: from ben_copy_entity_results

1374: order by information160;
1375: --
1376: Cursor csr_rm is
1377: Select information1
1378: from ben_copy_entity_results
1379: Where copy_entity_txn_id = p_copy_entity_txn_id
1380: AND table_alias = 'PLN';
1381: --
1382: Cursor csr_find_parent(p_rate_matrix_id in number, p_criteria_rate_defn_id in number) is

Line 1391: from ben_copy_entity_results

1387: and a.parent_criteria_rate_defn_id = b.criteria_rate_defn_id;
1388: --
1389: Cursor csr_is_parent_added(p_parent in number) is
1390: Select 'x'
1391: from ben_copy_entity_results
1392: Where table_alias = 'RCR'
1393: and copy_entity_txn_id = p_copy_entity_txn_id
1394: and information1 = p_parent;
1395: --

Line 1459: Update ben_copy_entity_results

1455: l_copy_entity_result_id := del_crd_row.copy_entity_result_id;
1456: l_curr_order_number := del_crd_row.information160;
1457: --
1458: --
1459: Update ben_copy_entity_results
1460: set information160 = l_new_order_number
1461: Where copy_entity_txn_id = p_copy_entity_txn_id
1462: and table_alias = 'RCR'
1463: and copy_entity_result_id = l_copy_entity_result_id;

Line 1494: from ben_copy_entity_results

1490: l_rcr_tr_name varchar2(150);
1491: --
1492: Cursor csr_next_order_num is
1493: Select max(information160) + 1
1494: from ben_copy_entity_results
1495: Where copy_entity_txn_id = p_copy_entity_txn_id
1496: and table_alias = 'RCR';
1497: --
1498: Begin

Line 1515: ben_copy_entity_results_api.create_copy_entity_results(

1511: p_table_name => l_rcr_tr_name);
1512: --
1513: -- When a new criteria rate definition is added, Add a RCR row with the correct
1514: -- order number and details
1515: ben_copy_entity_results_api.create_copy_entity_results(
1516: p_effective_date => trunc(sysdate)
1517: ,p_copy_entity_txn_id => p_copy_entity_txn_id
1518: ,p_result_type_cd => 'DISPLAY'
1519: ,p_table_name => l_rcr_tr_name

Line 1553: select max(nvl(information160,1))into l_max from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id

1549: if future_criteria_exist(p_copy_entity_txn_id) = 'YES' then
1550: return 'DisallowAdd';
1551: end if;
1552:
1553: select max(nvl(information160,1))into l_max from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id
1554: and table_alias in('RBC_CRIT', 'PLN') and dml_operation <> 'DELETE';
1555: if l_max < p_max_allowed then
1556: RETURN 'AllowAdd';
1557: else

Line 1571: from ben_copy_entity_results

1567: l_rate_matrix_node_id number;
1568: l_level_number number;
1569: -- p_mode in UPDATE or CREATE
1570: cursor c1 is select copy_entity_result_id, information160
1571: from ben_copy_entity_results
1572: where copy_entity_txn_id = p_copy_entity_txn_id
1573: and gs_parent_entity_result_id = p_copy_entity_result_id
1574: and table_alias in ('RMN','RMV');
1575: --Bug#9206953 vkodedal

Line 1577: from ben_copy_entity_results

1573: and gs_parent_entity_result_id = p_copy_entity_result_id
1574: and table_alias in ('RMN','RMV');
1575: --Bug#9206953 vkodedal
1576: cursor c2 is select information1,copy_entity_result_id
1577: from ben_copy_entity_results
1578: where copy_entity_txn_id = p_copy_entity_txn_id
1579: and (copy_entity_result_id = l_copy_entity_result_id
1580: or gs_parent_entity_result_id = l_copy_entity_result_id)
1581: and table_alias in ('RMN','RMV');

Line 1594: delete from ben_copy_entity_results

1590: l_level_number) = 'N')then
1591: delete_rate_values(p_copy_entity_txn_id, l_copy_entity_result_id);
1592: end if;
1593:
1594: delete from ben_copy_entity_results
1595: where INFORMATION1 = l_copy_entity_result_id
1596: and copy_entity_txn_id = p_copy_entity_txn_id
1597: and table_alias = 'RBR';
1598:

Line 1604: delete from ben_copy_entity_results

1600: loop
1601: --Bug#9206953 vkodedal
1602: fetch c2 into l_rate_matrix_node_id,l_copy_entity_result_id;
1603: EXIT WHEN c2%NOTFOUND;
1604: delete from ben_copy_entity_results
1605: where INFORMATION1 = l_rate_matrix_node_id
1606: and copy_entity_txn_id = p_copy_entity_txn_id
1607: and copy_entity_result_id=l_copy_entity_result_id
1608: and table_alias in ('RMV','RMN')

Line 1611: update ben_copy_entity_results

1607: and copy_entity_result_id=l_copy_entity_result_id
1608: and table_alias in ('RMV','RMN')
1609: and dml_operation = 'CREATE';
1610:
1611: update ben_copy_entity_results
1612: set dml_operation = 'DELETE',datetrack_mode = 'DELETE'
1613: where INFORMATION1 = l_rate_matrix_node_id
1614: and copy_entity_txn_id = p_copy_entity_txn_id
1615: and copy_entity_result_id=l_copy_entity_result_id

Line 1623: delete from ben_copy_entity_results

1619: end loop;
1620: close c2;
1621: end loop;
1622: close c1;
1623: delete from ben_copy_entity_results
1624: where INFORMATION1 = p_copy_entity_result_id
1625: and copy_entity_txn_id = p_copy_entity_txn_id
1626: and table_alias = 'RBR';
1627:

Line 1628: delete from ben_copy_entity_results

1624: where INFORMATION1 = p_copy_entity_result_id
1625: and copy_entity_txn_id = p_copy_entity_txn_id
1626: and table_alias = 'RBR';
1627:
1628: delete from ben_copy_entity_results
1629: where copy_entity_result_id = p_copy_entity_result_id
1630: and copy_entity_txn_id = p_copy_entity_txn_id
1631: and table_alias in ('RMV','RMN')
1632: and dml_operation = 'CREATE';

Line 1634: update ben_copy_entity_results

1630: and copy_entity_txn_id = p_copy_entity_txn_id
1631: and table_alias in ('RMV','RMN')
1632: and dml_operation = 'CREATE';
1633:
1634: update ben_copy_entity_results
1635: set dml_operation = 'DELETE',datetrack_mode = 'DELETE'
1636: where copy_entity_result_id = p_copy_entity_result_id
1637: and copy_entity_txn_id = p_copy_entity_txn_id
1638: and table_alias in ('RMV','RMN')

Line 1648: select max(information160) into l_max_level_number from ben_copy_entity_results

1644: p_copy_entity_result_id number,
1645: p_level_number number) return varchar2 is
1646: l_max_level_number number;
1647: begin
1648: select max(information160) into l_max_level_number from ben_copy_entity_results
1649: where copy_entity_txn_id = p_copy_entity_txn_id
1650: and table_alias = 'RBC_CRIT' and dml_operation <> 'DELETE';
1651:
1652: if(p_level_number = 1 or p_level_number < l_max_level_number) then

Line 1664: cursor c1 is select copy_entity_result_id from ben_copy_entity_results

1660: --
1661: procedure cancel_rate_matrix_txn(p_copy_entity_txn_id in number,p_status out nocopy varchar2) is
1662:
1663: l_copy_entity_result_id number;
1664: cursor c1 is select copy_entity_result_id from ben_copy_entity_results
1665: where copy_entity_txn_id = p_copy_entity_txn_id and table_alias = 'PLN';
1666:
1667: begin
1668: FND_MSG_PUB.initialize;

Line 1682: delete from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id;

1678:
1679:
1680:
1681: hr_utility.set_location('going for deleting entire rate matrix txn',100);
1682: delete from ben_copy_entity_results where copy_entity_txn_id = p_copy_entity_txn_id;
1683: delete from pqh_copy_entity_txns where copy_entity_txn_id = p_copy_entity_txn_id;
1684: hr_utility.set_location('deleting entire rate matrix txn done',110);
1685: exception
1686: when others then