1 Package ben_pln_shd AUTHID CURRENT_USER as
2 /* $Header: beplnrhi.pkh 120.2.12020000.4 2013/02/01 08:52:51 amnaraya ship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- | Global Record Type Specification |
6 -- ----------------------------------------------------------------------------
7 --
8 Type g_rec_type Is Record
9 (
10 PL_ID NUMBER(15)
11 ,EFFECTIVE_START_DATE DATE
12 ,EFFECTIVE_END_DATE DATE
13 ,NAME VARCHAR2(240) -- UTF8 Change Bug 2254683
14 ,ALWS_QDRO_FLAG VARCHAR2(30)
15 ,ALWS_QMCSO_FLAG VARCHAR2(30)
16 ,ALWS_REIMBMTS_FLAG VARCHAR2(30)
17 ,BNF_ADDL_INSTN_TXT_ALWD_FLAG VARCHAR2(30)
18 ,BNF_ADRS_RQD_FLAG VARCHAR2(30)
19 ,BNF_CNTNGT_BNFS_ALWD_FLAG VARCHAR2(30)
20 ,BNF_CTFN_RQD_FLAG VARCHAR2(30)
21 ,BNF_DOB_RQD_FLAG VARCHAR2(30)
22 ,BNF_DSGE_MNR_TTEE_RQD_FLAG VARCHAR2(30)
23 ,BNF_INCRMT_AMT NUMBER --(15)
24 ,BNF_DFLT_BNF_CD VARCHAR2(30)
25 ,BNF_LEGV_ID_RQD_FLAG VARCHAR2(30)
26 ,BNF_MAY_DSGT_ORG_FLAG VARCHAR2(30)
27 ,BNF_MN_DSGNTBL_AMT NUMBER --(15)
28 ,BNF_MN_DSGNTBL_PCT_VAL NUMBER(15,2) -- Bug 6012543, precision changed, (15) to (15,2).
29 ,rqd_perd_enrt_nenrt_val NUMBER(15)
30 ,ordr_num NUMBER(15)
31 ,BNF_PCT_INCRMT_VAL NUMBER(15,2) -- Bug 6012543, precision changed, (15) to (15,2).
32 ,BNF_PCT_AMT_ALWD_CD VARCHAR2(30)
33 ,BNF_QDRO_RL_APLS_FLAG VARCHAR2(30)
34 ,DFLT_TO_ASN_PNDG_CTFN_CD VARCHAR2(30)
35 ,DFLT_TO_ASN_PNDG_CTFN_RL NUMBER(15)
36 ,DRVBL_FCTR_APLS_RTS_FLAG VARCHAR2(30)
37 ,DRVBL_FCTR_PRTN_ELIG_FLAG VARCHAR2(30)
38 ,DPNT_DSGN_CD VARCHAR2(30)
39 ,ELIG_APLS_FLAG VARCHAR2(30)
40 ,INVK_DCLN_PRTN_PL_FLAG VARCHAR2(30)
41 ,INVK_FLX_CR_PL_FLAG VARCHAR2(30)
42 ,IMPTD_INCM_CALC_CD VARCHAR2(30)
43 ,DRVBL_DPNT_ELIG_FLAG VARCHAR2(30)
44 ,TRK_INELIG_PER_FLAG VARCHAR2(30)
45 ,PL_CD VARCHAR2(30)
46 ,AUTO_ENRT_MTHD_RL NUMBER(15)
47 ,IVR_IDENT VARCHAR2(90) -- UTF8 Change Bug 2254683
48 ,URL_REF_NAME VARCHAR2(240)
49 ,CMPR_CLMS_TO_CVG_OR_BAL_CD VARCHAR2(30)
50 ,COBRA_PYMT_DUE_DY_NUM NUMBER(15)
51 ,DPNT_CVD_BY_OTHR_APLS_FLAG VARCHAR2(30)
52 ,ENRT_MTHD_CD VARCHAR2(30)
53 ,ENRT_CD VARCHAR2(30)
54 ,ENRT_CVG_STRT_DT_CD VARCHAR2(30)
55 ,ENRT_CVG_END_DT_CD VARCHAR2(30)
56 ,FRFS_APLY_FLAG VARCHAR2(30)
57 ,HC_PL_SUBJ_HCFA_APRVL_FLAG VARCHAR2(30)
58 ,HGHLY_CMPD_RL_APLS_FLAG VARCHAR2(30)
59 ,INCPTN_DT DATE
60 ,MN_CVG_RL NUMBER(15)
61 ,MN_CVG_RQD_AMT NUMBER --(15)
62 ,MN_OPTS_RQD_NUM NUMBER(15)
63 ,MX_CVG_ALWD_AMT NUMBER --(15)
64 ,MX_CVG_RL NUMBER(15)
65 ,MX_OPTS_ALWD_NUM NUMBER(15)
66 ,MX_CVG_WCFN_MLT_NUM NUMBER(15)
67 ,MX_CVG_WCFN_AMT NUMBER --(15)
68 ,MX_CVG_INCR_ALWD_AMT NUMBER --(15)
69 ,MX_CVG_INCR_WCF_ALWD_AMT NUMBER --(15)
70 ,MX_CVG_MLT_INCR_NUM NUMBER(15)
71 ,MX_CVG_MLT_INCR_WCF_NUM NUMBER(15)
72 ,MX_WTG_DT_TO_USE_CD VARCHAR2(30)
73 ,MX_WTG_DT_TO_USE_RL NUMBER(15)
74 ,MX_WTG_PERD_PRTE_UOM VARCHAR2(30)
75 ,MX_WTG_PERD_PRTE_VAL NUMBER(15)
76 ,MX_WTG_PERD_RL NUMBER(15)
77 ,NIP_DFLT_ENRT_CD VARCHAR2(30)
78 ,NIP_DFLT_ENRT_DET_RL NUMBER(15)
79 ,DPNT_ADRS_RQD_FLAG VARCHAR2(30)
80 ,DPNT_CVG_END_DT_CD VARCHAR2(30)
81 ,DPNT_CVG_END_DT_RL NUMBER(15)
82 ,DPNT_CVG_STRT_DT_CD VARCHAR2(30)
83 ,DPNT_CVG_STRT_DT_RL NUMBER(15)
84 ,DPNT_DOB_RQD_FLAG VARCHAR2(30)
85 ,DPNT_LEG_ID_RQD_FLAG VARCHAR2(30)
86 ,DPNT_NO_CTFN_RQD_FLAG VARCHAR2(30)
87 ,NO_MN_CVG_AMT_APLS_FLAG VARCHAR2(30)
88 ,NO_MN_CVG_INCR_APLS_FLAG VARCHAR2(30)
89 ,NO_MN_OPTS_NUM_APLS_FLAG VARCHAR2(30)
90 ,NO_MX_CVG_AMT_APLS_FLAG VARCHAR2(30)
91 ,NO_MX_CVG_INCR_APLS_FLAG VARCHAR2(30)
92 ,NO_MX_OPTS_NUM_APLS_FLAG VARCHAR2(30)
93 ,NIP_PL_UOM VARCHAR2(30)
94 ,rqd_perd_enrt_nenrt_uom VARCHAR2(30)
95 ,NIP_ACTY_REF_PERD_CD VARCHAR2(30)
96 ,NIP_ENRT_INFO_RT_FREQ_CD VARCHAR2(30)
97 ,PER_CVRD_CD VARCHAR2(30)
98 ,ENRT_CVG_END_DT_RL NUMBER(15)
99 ,POSTELCN_EDIT_RL NUMBER(15)
100 ,ENRT_CVG_STRT_DT_RL NUMBER(15)
101 ,PRORT_PRTL_YR_CVG_RSTRN_CD VARCHAR2(30)
102 ,PRORT_PRTL_YR_CVG_RSTRN_RL NUMBER(15)
103 ,PRTN_ELIG_OVRID_ALWD_FLAG VARCHAR2(30)
104 ,SVGS_PL_FLAG VARCHAR2(30)
105 ,SUBJ_TO_IMPTD_INCM_TYP_CD VARCHAR2(30)
106 ,USE_ALL_ASNTS_ELIG_FLAG VARCHAR2(30)
107 ,USE_ALL_ASNTS_FOR_RT_FLAG VARCHAR2(30)
108 ,VSTG_APLS_FLAG VARCHAR2(30)
109 ,WVBL_FLAG VARCHAR2(30)
110 ,HC_SVC_TYP_CD VARCHAR2(30)
111 ,PL_STAT_CD VARCHAR2(30)
112 ,PRMRY_FNDG_MTHD_CD VARCHAR2(30)
113 ,RT_END_DT_CD VARCHAR2(30)
114 ,RT_END_DT_RL NUMBER(15)
115 ,RT_STRT_DT_RL NUMBER(15)
116 ,RT_STRT_DT_CD VARCHAR2(30)
117 ,BNF_DSGN_CD VARCHAR2(30)
118 ,PL_TYP_ID NUMBER(15)
119 ,BUSINESS_GROUP_ID NUMBER(15)
120 ,ENRT_PL_OPT_FLAG VARCHAR2(30)
121 ,BNFT_PRVDR_POOL_ID NUMBER(15)
122 ,MAY_ENRL_PL_N_OIPL_FLAG VARCHAR2(30)
123 ,ENRT_RL NUMBER
124 ,rqd_perd_enrt_nenrt_rl NUMBER
125 ,ALWS_UNRSTRCTD_ENRT_FLAG VARCHAR2(30)
126 ,BNFT_OR_OPTION_RSTRCTN_CD VARCHAR2(30)
127 ,CVG_INCR_R_DECR_ONLY_CD VARCHAR2(30)
128 ,unsspnd_enrt_cd VARCHAR2(30)
129 ,PLN_ATTRIBUTE_CATEGORY VARCHAR2(30)
130 ,PLN_ATTRIBUTE1 VARCHAR2(150)
131 ,PLN_ATTRIBUTE2 VARCHAR2(150)
132 ,PLN_ATTRIBUTE3 VARCHAR2(150)
133 ,PLN_ATTRIBUTE4 VARCHAR2(150)
134 ,PLN_ATTRIBUTE5 VARCHAR2(150)
135 ,PLN_ATTRIBUTE6 VARCHAR2(150)
136 ,PLN_ATTRIBUTE7 VARCHAR2(150)
137 ,PLN_ATTRIBUTE8 VARCHAR2(150)
138 ,PLN_ATTRIBUTE9 VARCHAR2(150)
139 ,PLN_ATTRIBUTE10 VARCHAR2(150)
140 ,PLN_ATTRIBUTE11 VARCHAR2(150)
141 ,PLN_ATTRIBUTE12 VARCHAR2(150)
142 ,PLN_ATTRIBUTE13 VARCHAR2(150)
143 ,PLN_ATTRIBUTE14 VARCHAR2(150)
144 ,PLN_ATTRIBUTE15 VARCHAR2(150)
145 ,PLN_ATTRIBUTE16 VARCHAR2(150)
146 ,PLN_ATTRIBUTE17 VARCHAR2(150)
147 ,PLN_ATTRIBUTE18 VARCHAR2(150)
148 ,PLN_ATTRIBUTE19 VARCHAR2(150)
149 ,PLN_ATTRIBUTE20 VARCHAR2(150)
150 ,PLN_ATTRIBUTE21 VARCHAR2(150)
151 ,PLN_ATTRIBUTE22 VARCHAR2(150)
152 ,PLN_ATTRIBUTE23 VARCHAR2(150)
153 ,PLN_ATTRIBUTE24 VARCHAR2(150)
154 ,PLN_ATTRIBUTE25 VARCHAR2(150)
155 ,PLN_ATTRIBUTE26 VARCHAR2(150)
156 ,PLN_ATTRIBUTE27 VARCHAR2(150)
157 ,PLN_ATTRIBUTE28 VARCHAR2(150)
158 ,PLN_ATTRIBUTE29 VARCHAR2(150)
159 ,PLN_ATTRIBUTE30 VARCHAR2(150)
160 ,susp_if_ctfn_not_prvd_flag varchar2(30)
161 ,ctfn_determine_cd varchar2(30)
162 ,susp_if_dpnt_ssn_nt_prv_cd varchar2(30)
163 ,susp_if_dpnt_dob_nt_prv_cd varchar2(30)
164 ,susp_if_dpnt_adr_nt_prv_cd varchar2(30)
165 ,susp_if_ctfn_not_dpnt_flag varchar2(30)
166 ,susp_if_bnf_ssn_nt_prv_cd varchar2(30)
167 ,susp_if_bnf_dob_nt_prv_cd varchar2(30)
168 ,susp_if_bnf_adr_nt_prv_cd varchar2(30)
169 ,susp_if_ctfn_not_bnf_flag varchar2(30)
170 ,dpnt_ctfn_determine_cd varchar2(30)
171 ,bnf_ctfn_determine_cd varchar2(30)
172 ,LAST_UPDATE_DATE DATE
173 ,LAST_UPDATED_BY NUMBER(15)
174 ,LAST_UPDATE_LOGIN NUMBER(15)
175 ,CREATED_BY NUMBER(15)
176 ,CREATION_DATE DATE
177 ,OBJECT_VERSION_NUMBER NUMBER(9)
178 ,ACTL_PREM_ID NUMBER(15)
179 ,VRFY_FMLY_MMBR_CD VARCHAR2(30)
180 ,VRFY_FMLY_MMBR_RL NUMBER(15)
181 ,ALWS_TMPRY_ID_CRD_FLAG VARCHAR2(30)
182 ,NIP_DFLT_FLAG VARCHAR2(30)
183 ,frfs_distr_mthd_cd VARCHAR2(30)
184 ,frfs_distr_mthd_rl NUMBER(15)
185 ,frfs_cntr_det_cd VARCHAR2(30)
186 ,frfs_distr_det_cd VARCHAR2(30)
187 ,cost_alloc_keyflex_1_id NUMBER(15)
188 ,cost_alloc_keyflex_2_id NUMBER(15)
189 ,post_to_gl_flag VARCHAR2(30)
190 ,frfs_val_det_cd VARCHAR2(30)
191 ,frfs_mx_cryfwd_val NUMBER(15)
192 ,frfs_portion_det_cd VARCHAR2(30)
193 ,bndry_perd_cd VARCHAR2(30)
194 ,short_name VARCHAR2(30)
195 ,short_code VARCHAR2(30)
196 ,legislation_code VARCHAR2(30)
197 ,legislation_subgroup VARCHAR2(30)
198 ,group_pl_id NUMBER
199 ,mapping_table_name VARCHAR2(60)
200 ,mapping_table_pk_id NUMBER
201 ,function_code VARCHAR2(30)
202 ,pl_yr_not_applcbl_flag VARCHAR2(30)
203 ,use_csd_rsd_prccng_cd VARCHAR2(30)
204 ,all_inelig VARCHAR2(30)
205 ,bnf_exl_participant_flag VARCHAR2(30) --Enh 16043887
206 );
207 --
208 -- ----------------------------------------------------------------------------
209 -- | Global Definitions - Internal Development Use Only |
210 -- ----------------------------------------------------------------------------
211 --
212 g_old_rec g_rec_type; -- Global record definition
213 g_api_dml boolean; -- Global api dml status
214 --
215 -- ----------------------------------------------------------------------------
216 -- |------------------------< return_api_dml_status >-------------------------|
217 -- ----------------------------------------------------------------------------
218 -- {Start Of Comments}
219 --
220 -- Description:
221 -- This function will return the current g_api_dml private global
222 -- boolean status.
223 -- The g_api_dml status determines if at the time of the function
224 -- being executed if a dml statement (i.e. INSERT, UPDATE or DELETE)
225 -- is being issued from within an api.
226 -- If the status is TRUE then a dml statement is being issued from
227 -- within this entity api.
228 -- This function is primarily to support database triggers which
229 -- need to maintain the object_version_number for non-supported
230 -- dml statements (i.e. dml statement issued outside of the api layer).
234 --
231 --
232 -- Prerequisites:
233 -- None.
235 -- In Parameters:
236 -- None.
237 --
238 -- Post Success:
239 -- Processing continues.
240 -- If the function returns a TRUE value then, dml is being executed from
241 -- within this api.
242 --
243 -- Post Failure:
244 -- None.
245 --
246 -- Access Status:
247 -- Internal Row Handler Use Only.
248 --
249 -- {End Of Comments}
250 -- ----------------------------------------------------------------------------
251 Function return_api_dml_status Return Boolean;
252 --
253 -- ----------------------------------------------------------------------------
254 -- |---------------------------< constraint_error >---------------------------|
255 -- ----------------------------------------------------------------------------
256 -- {Start Of Comments}
257 --
258 -- Description:
259 -- This procedure is called when a constraint has been violated (i.e.
260 -- The exception hr_api.check_integrity_violated,
261 -- hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
262 -- hr_api.unique_integrity_violated has been raised).
263 -- The exceptions can only be raised as follows:
264 -- 1) A check constraint can only be violated during an INSERT or UPDATE
265 -- dml operation.
266 -- 2) A parent integrity constraint can only be violated during an
267 -- INSERT or UPDATE dml operation.
268 -- 3) A child integrity constraint can only be violated during an
269 -- DELETE dml operation.
270 -- 4) A unique integrity constraint can only be violated during INSERT or
271 -- UPDATE dml operation.
272 --
273 -- Prerequisites:
274 -- 1) Either hr_api.check_integrity_violated,
275 -- hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
276 -- hr_api.unique_integrity_violated has been raised with the subsequent
277 -- stripping of the constraint name from the generated error message
278 -- text.
279 -- 2) Standalone validation test which corresponds with a constraint error.
280 --
281 -- In Parameter:
282 -- p_constraint_name is in upper format and is just the constraint name
283 -- (e.g. not prefixed by brackets, schema owner etc).
284 --
285 -- Post Success:
286 -- Development dependant.
287 --
288 -- Post Failure:
289 -- Developement dependant.
290 --
291 -- Developer Implementation Notes:
292 -- For each constraint being checked the hr system package failure message
293 -- has been generated as a template only. These system error messages should
294 -- be modified as required (i.e. change the system failure message to a user
295 -- friendly defined error message).
296 --
297 -- Access Status:
298 -- Internal Development Use Only.
299 --
300 -- {End Of Comments}
301 -- ----------------------------------------------------------------------------
302 Procedure constraint_error
303 (p_constraint_name in all_constraints.constraint_name%TYPE);
304 --
305 -- ----------------------------------------------------------------------------
306 -- |-----------------------------< api_updating >-----------------------------|
307 -- ----------------------------------------------------------------------------
308 -- {Start Of Comments}
309 --
310 -- Description:
311 -- This function is used to populate the g_old_rec record with the current
312 -- row from the database for the specified primary key provided that the
313 -- primary key exists, and is valid, and does not already match the current
314 -- g_old_rec.
315 -- The function will always return a TRUE value if the g_old_rec is
316 -- populated with the current row. A FALSE value will be returned if all of
317 -- the primary key arguments are null.
318 --
319 -- Prerequisites:
320 -- None.
321 --
322 -- In Parameters:
323 --
324 -- Post Success:
325 -- A value of TRUE will be returned indiciating that the g_old_rec is
326 -- current.
327 -- A value of FALSE will be returned if all of the primary key arguments
328 -- have a null value (this indicates that the row has not be inserted into
329 -- the Schema), and therefore could never have a corresponding row.
330 --
331 -- Post Failure:
332 -- A failure can only occur under two circumstances:
333 -- 1) The primary key is invalid (i.e. a row does not exist for the
334 -- specified primary key values).
335 -- 2) If an object_version_number exists but is NOT the same as the current
336 -- g_old_rec value.
337 --
338 -- Developer Implementation Notes:
339 -- None.
340 --
341 -- Access Status:
342 -- Internal Development Use Only.
343 --
344 -- {End Of Comments}
345 -- ----------------------------------------------------------------------------
346 Function api_updating
347 (p_effective_date in date,
348 p_pl_id in number,
349 p_object_version_number in number
350 ) Return Boolean;
351 --
352 -- ----------------------------------------------------------------------------
353 -- |--------------------------< find_dt_del_modes >---------------------------|
354 -- ----------------------------------------------------------------------------
355 -- {Start Of Comments}
356 --
357 -- Description:
358 -- This procedure is used to determine what datetrack delete modes are
359 -- allowed as of the effective date for this entity. The procedure will
360 -- return a corresponding Boolean value for each of the delete modes
361 -- available where TRUE indicates that the corresponding delete mode is
362 -- available.
363 --
364 -- Prerequisites:
365 -- None.
366 --
367 -- In Parameters:
368 -- p_effective_date
369 -- Specifies the date at which the datetrack modes will be operated on.
370 -- p_base_key_value
374 --
371 -- Specifies the primary key value for this datetrack entity.
372 -- (E.g. For this entity the assignment of the argument would be:
373 -- p_base_key_value = :pl_id).
375 -- Post Success:
376 -- Processing continues.
377 --
378 -- Post Failure:
379 -- Failure might occur if for the specified effective date and primary key
380 -- value a row doesn't exist.
381 --
382 -- Developer Implementation Notes:
383 -- This procedure could require changes if this entity has any sepcific
384 -- delete restrictions.
385 -- For example, this entity might disallow the datetrack delete mode of
386 -- ZAP. To implement this you would have to set and return a Boolean value
387 -- of FALSE after the call to the dt_api.find_dt_del_modes procedure.
388 --
389 -- Access Status:
390 -- Internal Development Use Only.
391 --
392 -- {End Of Comments}
393 -- ----------------------------------------------------------------------------
394 Procedure find_dt_del_modes
395 (p_effective_date in date,
396 p_base_key_value in number,
397 p_zap out nocopy boolean,
398 p_delete out nocopy boolean,
399 p_future_change out nocopy boolean,
400 p_delete_next_change out nocopy boolean);
401 --
402 -- ----------------------------------------------------------------------------
403 -- |--------------------------< find_dt_upd_modes >---------------------------|
404 -- ----------------------------------------------------------------------------
405 -- {Start Of Comments}
406 --
407 -- Description:
408 -- This procedure is used to determine what datetrack update modes are
409 -- allowed as of the effective date for this entity. The procedure will
410 -- return a corresponding Boolean value for each of the update modes
411 -- available where TRUE indicates that the corresponding update mode
412 -- is available.
413 --
414 -- Prerequisites:
415 -- None.
416 --
417 -- In Parameters:
418 -- p_effective_date
419 -- Specifies the date at which the datetrack modes will be operated on.
420 -- p_base_key_value
421 -- Specifies the primary key value for this datetrack entity.
422 -- (E.g. For this entity the assignment of the argument would be:
423 -- p_base_key_value = :pl_id).
424 --
425 -- Post Success:
426 -- Processing continues.
427 --
428 -- Post Failure:
429 -- Failure might occur if for the specified effective date and primary key
430 -- value a row doesn't exist.
431 --
432 -- Developer Implementation Notes:
433 -- This procedure could require changes if this entity has any sepcific
434 -- delete restrictions.
435 -- For example, this entity might disallow the datetrack update mode of
436 -- UPDATE. To implement this you would have to set and return a Boolean
437 -- value of FALSE after the call to the dt_api.find_dt_upd_modes procedure.
438 --
439 -- Access Status:
440 -- Internal Development Use Only.
441 --
442 -- {End Of Comments}
443 -- ----------------------------------------------------------------------------
444 Procedure find_dt_upd_modes
445 (p_effective_date in date,
446 p_base_key_value in number,
447 p_correction out nocopy boolean,
448 p_update out nocopy boolean,
449 p_update_override out nocopy boolean,
450 p_update_change_insert out nocopy boolean);
451 --
452 -- ----------------------------------------------------------------------------
453 -- |------------------------< upd_effective_end_date >------------------------|
454 -- ----------------------------------------------------------------------------
455 -- {Start Of Comments}
456 --
457 -- Description:
458 -- This procedure will update the specified datetrack row with the
459 -- specified new effective end date. The object version number is also
460 -- set to the next object version number. DateTrack modes which call
461 -- this procedure are: UPDATE, UPDATE_CHANGE_INSERT,
462 -- UPDATE_OVERRIDE, DELETE, FUTURE_CHANGE and DELETE_NEXT_CHANGE.
463 -- This is an internal datetrack maintenance procedure which should
464 -- not be modified in anyway.
465 --
466 -- Prerequisites:
467 -- None.
468 --
469 -- In Parameters:
470 -- p_new_effective_end_date
471 -- Specifies the new effective end date which will be set for the
472 -- row as of the effective date.
473 -- p_base_key_value
474 -- Specifies the primary key value for this datetrack entity.
475 -- (E.g. For this entity the assignment of the argument would be:
476 -- p_base_key_value = :pl_id).
477 --
478 -- Post Success:
479 -- The specified row will be updated with the new effective end date and
480 -- object_version_number.
481 --
482 -- Post Failure:
483 -- Failure might occur if for the specified effective date and primary key
484 -- value a row doesn't exist.
485 --
486 -- Developer Implementation Notes:
487 -- This is an internal datetrack maintenance procedure which should
488 -- not be modified in anyway.
489 --
490 -- Access Status:
491 -- Internal Row Handler Use Only.
492 --
493 -- {End Of Comments}
494 -- ----------------------------------------------------------------------------
495 Procedure upd_effective_end_date
496 (p_effective_date in date,
497 p_base_key_value in number,
498 p_new_effective_end_date in date,
499 p_validation_start_date in date,
500 p_validation_end_date in date,
501 p_object_version_number out nocopy number);
502 --
503 -- ----------------------------------------------------------------------------
504 -- |---------------------------------< lck >----------------------------------|
505 -- ----------------------------------------------------------------------------
506 -- {Start Of Comments}
507 --
511 -- The processing steps are as follows:
508 -- Description:
509 -- The Lck process for datetrack is complicated and comprises of the
510 -- following processing
512 -- 1) The row to be updated or deleted must be locked.
513 -- By locking this row, the g_old_rec record data type is populated.
514 -- 2) If a comment exists the text is selected from hr_comments.
515 -- 3) The datetrack mode is then validated to ensure the operation is
516 -- valid. If the mode is valid the validation start and end dates for
517 -- the mode will be derived and returned. Any required locking is
518 -- completed when the datetrack mode is validated.
519 --
520 -- Prerequisites:
521 -- When attempting to call the lck procedure the object version number,
522 -- primary key, effective date and datetrack mode must be specified.
523 --
524 -- In Parameters:
525 -- p_effective_date
526 -- Specifies the date of the datetrack update operation.
527 -- p_datetrack_mode
528 -- Determines the datetrack update or delete mode.
529 --
530 -- Post Success:
531 -- On successful completion of the Lck process the row to be updated or
532 -- deleted will be locked and selected into the global data structure
533 -- g_old_rec.
534 --
535 -- Post Failure:
536 -- The Lck process can fail for three reasons:
537 -- 1) When attempting to lock the row the row could already be locked by
538 -- another user. This will raise the HR_Api.Object_Locked exception.
539 -- 2) The row which is required to be locked doesn't exist in the HR Schema.
540 -- This error is trapped and reported using the message name
541 -- 'HR_7220_INVALID_PRIMARY_KEY'.
542 -- 3) The row although existing in the HR Schema has a different object
543 -- version number than the object version number specified.
544 -- This error is trapped and reported using the message name
545 -- 'HR_7155_OBJECT_INVALID'.
546 --
547 -- Developer Implementation Notes:
548 -- None.
549 --
550 -- Access Status:
551 -- Internal Development Use Only.
552 --
553 -- {End Of Comments}
554 -- ----------------------------------------------------------------------------
555 Procedure lck
556 (p_effective_date in date,
557 p_datetrack_mode in varchar2,
558 p_pl_id in number,
559 p_object_version_number in number,
560 p_validation_start_date out nocopy date,
561 p_validation_end_date out nocopy date);
562 --
563 -- ----------------------------------------------------------------------------
564 -- |-----------------------------< convert_args >-----------------------------|
565 -- ----------------------------------------------------------------------------
566 -- {Start Of Comments}
567 --
568 -- Description:
569 -- This function is used to turn attribute parameters into the record
570 -- structure parameter g_rec_type.
571 --
572 -- Prerequisites:
573 -- This is a private function and can only be called from the ins or upd
574 -- attribute processes.
575 --
576 -- In Parameters:
577 --
578 -- Post Success:
579 -- A returning record structure will be returned.
580 --
581 -- Post Failure:
582 -- No direct error handling is required within this function. Any possible
583 -- errors within this function will be a PL/SQL value error due to conversion
584 -- of datatypes or data lengths.
585 --
586 -- Developer Implementation Notes:
587 -- None.
588 --
589 -- Access Status:
590 -- Internal Row Handler Use Only.
591 --
592 -- {End Of Comments}
593 -- ----------------------------------------------------------------------------
594 Function convert_args
595 (
596 p_pl_id in number,
597 p_effective_start_date in date,
598 p_effective_end_date in date,
599 p_name in varchar2,
600 p_alws_qdro_flag in varchar2,
601 p_alws_qmcso_flag in varchar2,
602 p_alws_reimbmts_flag in varchar2,
603 p_bnf_addl_instn_txt_alwd_flag in varchar2,
604 p_bnf_adrs_rqd_flag in varchar2,
605 p_bnf_cntngt_bnfs_alwd_flag in varchar2,
606 p_bnf_ctfn_rqd_flag in varchar2,
607 p_bnf_dob_rqd_flag in varchar2,
608 p_bnf_dsge_mnr_ttee_rqd_flag in varchar2,
609 p_bnf_incrmt_amt in number,
610 p_bnf_dflt_bnf_cd in varchar2,
611 p_bnf_legv_id_rqd_flag in varchar2,
612 p_bnf_may_dsgt_org_flag in varchar2,
613 p_bnf_mn_dsgntbl_amt in number,
614 p_bnf_mn_dsgntbl_pct_val in number,
615 p_rqd_perd_enrt_nenrt_val in number,
616 p_ordr_num in number,
617 p_bnf_pct_incrmt_val in number,
618 p_bnf_pct_amt_alwd_cd in varchar2,
619 p_bnf_qdro_rl_apls_flag in varchar2,
620 p_dflt_to_asn_pndg_ctfn_cd in varchar2,
621 p_dflt_to_asn_pndg_ctfn_rl in number,
622 p_drvbl_fctr_apls_rts_flag in varchar2,
623 p_drvbl_fctr_prtn_elig_flag in varchar2,
624 p_dpnt_dsgn_cd in varchar2,
625 p_elig_apls_flag in varchar2,
626 p_invk_dcln_prtn_pl_flag in varchar2,
627 p_invk_flx_cr_pl_flag in varchar2,
628 p_imptd_incm_calc_cd in varchar2,
629 p_drvbl_dpnt_elig_flag in varchar2,
630 p_trk_inelig_per_flag in varchar2,
631 p_pl_cd in varchar2,
632 p_auto_enrt_mthd_rl in number,
633 p_ivr_ident in varchar2,
634 p_url_ref_name in varchar2,
635 p_cmpr_clms_to_cvg_or_bal_cd in varchar2,
636 p_cobra_pymt_due_dy_num in number,
637 p_dpnt_cvd_by_othr_apls_flag in varchar2,
638 p_enrt_mthd_cd in varchar2,
639 p_enrt_cd in varchar2,
643 p_hc_pl_subj_hcfa_aprvl_flag in varchar2,
640 p_enrt_cvg_strt_dt_cd in varchar2,
641 p_enrt_cvg_end_dt_cd in varchar2,
642 p_frfs_aply_flag in varchar2,
644 p_hghly_cmpd_rl_apls_flag in varchar2,
645 p_incptn_dt in date,
646 p_mn_cvg_rl in number,
647 p_mn_cvg_rqd_amt in number,
648 p_mn_opts_rqd_num in number,
649 p_mx_cvg_alwd_amt in number,
650 p_mx_cvg_rl in number,
651 p_mx_opts_alwd_num in number,
652 p_mx_cvg_wcfn_mlt_num in number,
653 p_mx_cvg_wcfn_amt in number,
654 p_mx_cvg_incr_alwd_amt in number,
655 p_mx_cvg_incr_wcf_alwd_amt in number,
656 p_mx_cvg_mlt_incr_num in number,
657 p_mx_cvg_mlt_incr_wcf_num in number,
658 p_mx_wtg_dt_to_use_cd in varchar2,
659 p_mx_wtg_dt_to_use_rl in number,
660 p_mx_wtg_perd_prte_uom in varchar2,
661 p_mx_wtg_perd_prte_val in number,
662 p_mx_wtg_perd_rl in number,
663 p_nip_dflt_enrt_cd in varchar2,
664 p_nip_dflt_enrt_det_rl in number,
665 p_dpnt_adrs_rqd_flag in varchar2,
666 p_dpnt_cvg_end_dt_cd in varchar2,
667 p_dpnt_cvg_end_dt_rl in number,
668 p_dpnt_cvg_strt_dt_cd in varchar2,
669 p_dpnt_cvg_strt_dt_rl in number,
670 p_dpnt_dob_rqd_flag in varchar2,
671 p_dpnt_leg_id_rqd_flag in varchar2,
672 p_dpnt_no_ctfn_rqd_flag in varchar2,
673 p_no_mn_cvg_amt_apls_flag in varchar2,
674 p_no_mn_cvg_incr_apls_flag in varchar2,
675 p_no_mn_opts_num_apls_flag in varchar2,
676 p_no_mx_cvg_amt_apls_flag in varchar2,
677 p_no_mx_cvg_incr_apls_flag in varchar2,
678 p_no_mx_opts_num_apls_flag in varchar2,
679 p_nip_pl_uom in varchar2,
680 p_rqd_perd_enrt_nenrt_uom in varchar2,
681 p_nip_acty_ref_perd_cd in varchar2,
682 p_nip_enrt_info_rt_freq_cd in varchar2,
683 p_per_cvrd_cd in varchar2,
684 p_enrt_cvg_end_dt_rl in number,
685 p_postelcn_edit_rl in number,
686 p_enrt_cvg_strt_dt_rl in number,
687 p_prort_prtl_yr_cvg_rstrn_cd in varchar2,
688 p_prort_prtl_yr_cvg_rstrn_rl in number,
689 p_prtn_elig_ovrid_alwd_flag in varchar2,
690 p_svgs_pl_flag in varchar2,
691 p_subj_to_imptd_incm_typ_cd in varchar2,
692 p_use_all_asnts_elig_flag in varchar2,
693 p_use_all_asnts_for_rt_flag in varchar2,
694 p_vstg_apls_flag in varchar2,
695 p_wvbl_flag in varchar2,
696 p_hc_svc_typ_cd in varchar2,
697 p_pl_stat_cd in varchar2,
698 p_prmry_fndg_mthd_cd in varchar2,
699 p_rt_end_dt_cd in varchar2,
700 p_rt_end_dt_rl in number,
701 p_rt_strt_dt_rl in number,
702 p_rt_strt_dt_cd in varchar2,
703 p_bnf_dsgn_cd in varchar2,
704 p_pl_typ_id in number,
705 p_business_group_id in number,
706 p_enrt_pl_opt_flag in varchar2,
707 p_bnft_prvdr_pool_id in number,
708 p_MAY_ENRL_PL_N_OIPL_FLAG in VARCHAR2,
709 p_ENRT_RL in NUMBER,
710 p_rqd_perd_enrt_nenrt_rl in NUMBER,
711 p_ALWS_UNRSTRCTD_ENRT_FLAG in VARCHAR2,
712 p_BNFT_OR_OPTION_RSTRCTN_CD in VARCHAR2,
713 p_CVG_INCR_R_DECR_ONLY_CD in VARCHAR2,
714 p_unsspnd_enrt_cd in varchar2,
715 p_pln_attribute_category in varchar2,
716 p_pln_attribute1 in varchar2,
717 p_pln_attribute2 in varchar2,
718 p_pln_attribute3 in varchar2,
719 p_pln_attribute4 in varchar2,
720 p_pln_attribute5 in varchar2,
721 p_pln_attribute6 in varchar2,
722 p_pln_attribute7 in varchar2,
723 p_pln_attribute8 in varchar2,
724 p_pln_attribute9 in varchar2,
725 p_pln_attribute10 in varchar2,
726 p_pln_attribute11 in varchar2,
727 p_pln_attribute12 in varchar2,
728 p_pln_attribute13 in varchar2,
729 p_pln_attribute14 in varchar2,
730 p_pln_attribute15 in varchar2,
731 p_pln_attribute16 in varchar2,
732 p_pln_attribute17 in varchar2,
733 p_pln_attribute18 in varchar2,
734 p_pln_attribute19 in varchar2,
735 p_pln_attribute20 in varchar2,
736 p_pln_attribute21 in varchar2,
737 p_pln_attribute22 in varchar2,
738 p_pln_attribute23 in varchar2,
739 p_pln_attribute24 in varchar2,
740 p_pln_attribute25 in varchar2,
741 p_pln_attribute26 in varchar2,
742 p_pln_attribute27 in varchar2,
743 p_pln_attribute28 in varchar2,
744 p_pln_attribute29 in varchar2,
745 p_pln_attribute30 in varchar2,
746 p_susp_if_ctfn_not_prvd_flag in varchar2,
747 p_ctfn_determine_cd in varchar2,
748 p_susp_if_dpnt_ssn_nt_prv_cd in varchar2,
749 p_susp_if_dpnt_dob_nt_prv_cd in varchar2,
750 p_susp_if_dpnt_adr_nt_prv_cd in varchar2,
751 p_susp_if_ctfn_not_dpnt_flag in varchar2,
752 p_susp_if_bnf_ssn_nt_prv_cd in varchar2,
753 p_susp_if_bnf_dob_nt_prv_cd in varchar2,
754 p_susp_if_bnf_adr_nt_prv_cd in varchar2,
755 p_susp_if_ctfn_not_bnf_flag in varchar2,
756 p_dpnt_ctfn_determine_cd in varchar2,
757 p_bnf_ctfn_determine_cd in varchar2,
758 p_object_version_number in number,
759 p_actl_prem_id in number,
760 p_vrfy_fmly_mmbr_cd in varchar2,
761 p_vrfy_fmly_mmbr_rl in number,
762 p_ALWS_TMPRY_ID_CRD_FLAG in VARCHAR2,
763 p_nip_dflt_flag in VARCHAR2,
764 p_frfs_distr_mthd_cd in varchar2,
765 p_frfs_distr_mthd_rl in number,
766 p_frfs_cntr_det_cd in varchar2,
767 p_frfs_distr_det_cd in varchar2,
768 p_cost_alloc_keyflex_1_id in number,
769 p_cost_alloc_keyflex_2_id in number,
770 p_post_to_gl_flag in varchar2,
771 p_frfs_val_det_cd in varchar2,
772 p_frfs_mx_cryfwd_val in number,
773 p_frfs_portion_det_cd in varchar2,
774 p_bndry_perd_cd in varchar2,
775 p_short_name in varchar2,
776 p_short_code in varchar2,
777 p_legislation_code in varchar2,
778 p_legislation_subgroup in varchar2,
779 p_group_pl_id in number,
780 p_mapping_table_name in varchar2,
781 p_mapping_table_pk_id in number,
782 p_function_code in varchar2,
783 p_pl_yr_not_applcbl_flag in varchar2,
784 p_use_csd_rsd_prccng_cd in VARCHAR2,
785 p_all_inelig in varchar2,
786 p_bnf_exl_participant_flag in varchar2 --Enh 16043887
787 )
788 Return g_rec_type;
789 --
790 end ben_pln_shd;