DBA Data[Home] [Help]

PACKAGE: APPS.PER_HRTCA_MERGE

Source


1 package per_hrtca_merge AUTHID CURRENT_USER as
2 /* $Header: perhrtca.pkh 120.4 2011/09/30 12:24:43 vepravee ship $ */
3   --
4   g_prev_last_name_len number default null;
5   --
6 --bug no 5546586 starts here
7   g_old_email_address        per_all_people_f.email_address%type;
8 --bug no 5546586 ends here
9 
10   TYPE g_party_id_type IS TABLE OF NUMBER(15) index by binary_integer;
11   --
12   procedure migrate_all_hr_persons
13     (p_number_of_workers in number default 1,
14      p_current_worker    in number default 1);
15   --
16   procedure migrate_all_hr_email
17     (p_number_of_workers in number default 1,
18      p_current_worker    in number default 1);
19   --
20   procedure migrate_all_hr_gender
21     (p_number_of_workers in number default 1,
22      p_current_worker    in number default 1);
23   --
24   procedure create_tca_person
25     (p_rec                in out nocopy per_all_people_f%rowtype);
26   --
27   procedure update_tca_person
28     (p_rec                in out nocopy per_all_people_f%rowtype,
29      p_overwrite_data     in varchar2 default 'Y');
30   --
31   procedure replicate_person_across_bg
32     (p_rec                in out nocopy per_all_people_f%rowtype,
33      p_overwrite_data     in varchar2 default 'Y');
34   --
35 
36 /*Modified the parameters in the procedure create_update_contact_point to avoid the performance issue in bug#12933615*/
37   procedure create_update_contact_point
38     (p_party_id           in  per_all_people_f.party_id%type,
39      p_email_address      in  per_all_people_f.email_address%type);
40   --
41   procedure per_party_merge
42     (p_entity_name        in  varchar2,
43      p_from_id            in  number,
44      p_to_id              out nocopy number,
45      p_from_fk_id         in  number,
46      p_to_fk_id           in  number,
47      p_parent_entity_name in  varchar2,
48      p_batch_id           in  number,
49      p_batch_party_id     in  number,
50      p_return_status      out nocopy varchar2);
51   --
52   -- ------------------------------------------------------------------------------
53   -- |------------------------------< partyCleanup >------------------------------|
54   -- ------------------------------------------------------------------------------
55   --
56   -- procedure to process a range of rowids and purge party data when
57   -- required.
58   --
59     procedure partyCleanup(
60       p_process_ctrl    IN            varchar2,
61       p_start_rowid     IN            rowid,
62       p_end_rowid       IN            rowid,
63       p_rows_processed    OUT nocopy number);
64   --
65   -- ------------------------------------------------------------------------------
66   -- |------------------------< partycleanup_full_conc >--------------------------|
67   -- ------------------------------------------------------------------------------
68   --
69   procedure partycleanup_full_conc(errbuf        out NOCOPY  varchar2,
70                                    retcode       out NOCOPY  varchar2
71                                   );
72   --
73   --
74   -- ------------------------------------------------------------------------------
75   -- |------------------------< partycleanup_tca_conc >--------------------------|
76   -- ------------------------------------------------------------------------------
77   --
78   procedure partycleanup_tca_conc(errbuf        out NOCOPY  varchar2,
79                                   retcode       out NOCOPY  varchar2);
80   --
81   -- ------------------------------------------------------------------------------
82   -- |------------------------< CHK_GUPUD_RUN_BOOLEAN >--------------------------|
83   -- ------------------------------------------------------------------------------
84   --
85   procedure CHK_GUPUD_RUN_BOOLEAN(retstring     out NOCOPY  varchar2);
86   --
87   -- ----------------------------------------------------------------------------
88   -- |----------------------------< get_party_details >-------------------------|
89   -- ----------------------------------------------------------------------------
90   -- {Start Of Comments}
91   --
92   -- Description:
93   --   This function will return a single record for a given party id and
94   --   effective date
95   --
96   -- Prerequisites:
97   --   A valid record should be existing in per_all_people_f table for the
98   --   given party id and effective date
99   --
100   -- In Parameters:
101   --   Name                        Reqd   Type     Description
102   --   p_party_id                  Yes    Number   Party identifier
103   --   p_effective_date            Yes    Date     Effective date (Session date)
104   --
105   -- Post Success:
106   --   A single record will be returned for the given party id and effective date
107   --
108   -- Post Failure:
109   --   None
110   --
111   -- Access Status:
112   --   Public.
113   --
114   -- {End Of Comments}
115   --
116   -- ---------------------------------------------------------------------------
117     function get_party_details
118       (p_party_id           in number,
119        p_effective_date     in date) return per_per_shd.g_rec_type;
120   --
121   --
122   -- ------------------------------------------------------------------------------
123   -- |--------------------------< get_tca_merge_actions >-----------------------|
124   -- ------------------------------------------------------------------------------
125   --
126   -- Description:
127   --   This function will return an action to be performed. This function
128   --   returns one of the following actions.
129   --
130   --        'CREATE PARTY'
131   --        'AVOID CREATE PARTY'
132   --        'PARTY VALID'
133   --        'PARTY INVALID'
134   --
135   -- Prerequisites:
136   --   A valid record should be existing in per_all_people_f table for the
137   --   given party id and effective date
138   --
139   -- In Parameters:
140   --   Name                        Reqd   Type     Description
141   --   p_person_id                 Yes    Number   Person Identifier
142   --   p_party_id                  Yes    Number   Party identifier
143   --
144   -- Post Success:
145   --   Function returns actions to be performed depending upon the person_id,
146   --   party_id and the system_person_type, at the end of time.
147   --
148   -- Post Failure:
149   --   None
150   --
151   -- Access Status:
152   --   Public.
153   --
154   -- {End Of Comments}
155   --
156   -- ---------------------------------------------------------------------------
157   --
158   FUNCTION get_tca_merge_actions
159     (p_person_id  in number
160     ,p_party_id   in number
161     )
162   RETURN VARCHAR2;
163   --
164   --
165   -- ----------------------------------------------------------------------------
166   -- |----------------------------< get_person_details >-------------------------|
167   -- ----------------------------------------------------------------------------
168   -- {Start Of Comments}
169   --
170   -- Description:
171   --   This function will return a single record for a given party id, person_id and
172   --   effective date
173   --
174   -- Prerequisites:
175   --   A valid record should be existing in per_all_people_f table for the
176   --   given party id,person id and effective date
177   --
178   -- In Parameters:
179   --   Name                        Reqd   Type     Description
180   --   p_party_id                  Yes    Number   Party identifier
181   --   p_person_id                 Yes    Number   Person Identifier
182   --   p_effective_date            Yes    Date     Effective date (Session date)
183   --
184   -- Post Success:
185   --   A single record will be returned for the given party id,person_id and effective
186   --   date
187   --
188   -- Post Failure:
189   --   None
190   --
191   -- Access Status:
192   --   Public.
193   --
194   -- {End Of Comments}
195   --
196   -- ---------------------------------------------------------------------------
197   function get_person_details
198            (p_party_id           in number,
199             p_person_id          in number,
200             p_effective_date     in date) return per_per_shd.g_rec_type;
201   --
202   --
203   -- ----------------------------------------------------------------------------
204   -- |-------------------------< migrate_all_hr_persons >-----------------------|
205   -- ----------------------------------------------------------------------------
206   -- {Start Of Comments}
207   --
208   -- Description:
209   --   Procedure to update the party id for the valid persons.This is called from
210   --   the upgrade script perhrtca3.sql.
211   --
212   -- Prerequisites:
213   --   None
214   --
215   -- In Parameters:
216   --   Name                        Reqd   Type     Description
217   --   p_start_rowid               Yes    Rowid    Starting Person rowid in this range
218   --   p_end_rowid                 Yes    Rowid    Final Person rowid in this range
219   --
220   -- Out Parameters:
221   --   Name                        Reqd   Type     Description
222   --   p_rows_processed            Yes    Number   Number of rows processed.
223   --
224   -- Post Success:
225   --   Number of records processed will be assigned to p_row_processed.
226   --
227   -- Post Failure:
228   --   None
229   --
230   -- Access Status:
231   --   Public.
232   --
233   -- {End Of Comments}
234   --
235   -- ---------------------------------------------------------------------------
236   procedure migrate_all_hr_persons(p_start_rowid in rowid,
237                                  p_end_rowid in rowid,
238                                  p_rows_processed out NOCOPY number);
239   --
240   -- ----------------------------------------------------------------------------
241   -- |-------------------------< migrate_all_hr_email >-----------------------|
242   -- ----------------------------------------------------------------------------
243   -- {Start Of Comments}
244   --
245   -- Description:
246   --   Procedure to migrate hr_email for the valid persons.This is called from
247   --   the upgrade script peremtca2.sql.
248   --
249   -- Prerequisites:
250   --   None
251   --
252   -- In Parameters:
253   --   Name                        Reqd   Type     Description
254   --   p_start_rowid               Yes    Rowid    Starting Person rowid in this range
255   --   p_end_rowid                 Yes    Rowid    Final Person rowid in this range
256   --
257   -- Out Parameters:
258   --   Name                        Reqd   Type     Description
259   --   p_rows_processed            Yes    Number   Number of rows processed.
260   --
261   -- Post Success:
262   --   Number of records processed will be assigned to p_row_processed.
263   --
264   -- Post Failure:
265   --   None
266   --
267   -- Access Status:
268   --   Public.
269   --
270   -- {End Of Comments}
271   --
272    procedure migrate_all_hr_email(p_start_rowid in rowid,
273                                  p_end_rowid in rowid,
274                                  p_rows_processed out NOCOPY number);
275   --
276   /* Added this for the bug 5395601  */
277   Procedure purge_person(
278 			p_person_id  in number
279 		       ,p_party_id   in number
280 		        );
281   --
282 
283 end per_hrtca_merge;
284 --