DBA Data[Home] [Help]

PACKAGE: APPS.HZ_MIXNM_UTILITY

Source


1 PACKAGE HZ_MIXNM_UTILITY AS
2 /*$Header: ARHXUTLS.pls 120.6 2005/07/07 06:59:28 dmmehta noship $ */
3 
4 --------------------------------------------------------------------------
5 -- declaration of user defined type
6 --------------------------------------------------------------------------
7 
8 TYPE INDEXVARCHAR30List IS TABLE OF VARCHAR2(30) INDEX BY BINARY_INTEGER;
9 TYPE INDEXVARCHAR1List IS TABLE OF VARCHAR2(1) INDEX BY BINARY_INTEGER;
10 
11 --------------------------------------------------------------------------
12 -- declaration of public procedures and functions
13 --------------------------------------------------------------------------
14 
15 /**
16  * FUNCTION FindDataSource
17  *
18  * DESCRIPTION
19  *    Finds real data source based on content_source_type
20  *    and actual_content_source. This is for backward
21  *    compatibility because even the content_source_type is
22  *    obsolete, we can not assume user will not pass the
23  *    value into this column anymore.
24  *
25  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
26  *
27  * ARGUMENTS
28  *   IN:
29  *     p_content_source_type        Value of obsolete column content_source_type
30  *     p_actual_content_source      Value of new column actual_content_source
31  *     p_def_actual_content_source  Default value of new column actual_content_source
32  *   OUT:
33  *     x_data_source_from           Column name of where real data source is from.
34  *
35  * NOTES
36  *
37  * MODIFICATION HISTORY
38  *
39  *   03-01-2002    Jianying Huang   o Created.
40  */
41 
42 FUNCTION FindDataSource (
43     p_content_source_type           IN     VARCHAR2,
44     p_actual_content_source         IN     VARCHAR2,
45     p_def_actual_content_source     IN     VARCHAR2,
46     x_data_source_from              OUT    NOCOPY VARCHAR2
47 ) RETURN VARCHAR2;
48 
49 /**
50  * FUNCTION CheckUserCreationPrivilege
51  *
52  * DESCRIPTION
53  *   Check if user has privilege to create user entered data when
54  *   after mix-n-match is enabled.
55  *
56  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
57  *
58  * ARGUMENTS
59  *   IN:
60  *     p_entity_name                Entity name. Can not be party profiles.
61  *     p_entity_attr_id             Entity id. Entity id is used only for
62  *                                  performance consideration. It can speed
63  *                                  the query if it is passed.
64  *     p_mixnmatch_enabled          'Y'/'N' flag to indicate if mix-n-match
65  *                                  if enabled for this entity. You can get
66  *                                  the info. via HZ_MIXNM_UTILITY.
67  *     p_actual_content_source      Actual content source.
68  *   OUT:
69  *     x_return_status              Return FND_API.G_RET_STS_ERROR if the
70  *                                  user under this site/application/
71  *                                  responsibility is not allowed to create
72  *                                  user-entered data for this entity.
73  *
74  * NOTES
75  *   The procedure can only be called for other entities like HZ_CONTACT_POINTS,
76  *   HZ_LOCATIONS etc. It can not be called on party profiles HZ_ORGANIZATION_PROFILES,
77  *   HZ_PERSON_PROFILES.
78  *
79  * MODIFICATION HISTORY
80  *
81  *   03-01-2002    Jianying Huang   o Created.
82  */
83 /**
84  * FUNCTION CheckUserCreationPrivilege
85  *
86  * DESCRIPTION
87  *   Check if user has privilege to create user entered data when
88  *   after mix-n-match is enabled.
89  *
90  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
91  *
92  * ARGUMENTS
93  *   IN:
94  *     p_entity_name                Entity name. Can not be party profiles.
95  *     p_entity_attr_id             Entity id. Entity id is used only for
96  *                                  performance consideration. It can speed
97  *                                  the query if it is passed.
98  *     p_mixnmatch_enabled          'Y'/'N' flag to indicate if mix-n-match
99  *                                  if enabled for this entity. You can get
100  *                                  the info. via HZ_MIXNM_UTILITY.
101  *     p_actual_content_source      Actual content source.
102  *   OUT:
103  *     x_return_status              Return FND_API.G_RET_STS_ERROR if the
104  *                                  user under this site/application/
105  *                                  responsibility is not allowed to create
106  *                                  user-entered data for this entity.
107  *
108  * NOTES
109  *   The procedure can only be called for other entities like HZ_CONTACT_POINTS,
110  *   HZ_LOCATIONS etc. It can not be called on party profiles HZ_ORGANIZATION_PROFILES,
111  *   HZ_PERSON_PROFILES.
112  *
113  * MODIFICATION HISTORY
114  *
115  *   03-01-2002    Jianying Huang      o Created.
116  */
117 
118 PROCEDURE CheckUserCreationPrivilege (
119     p_entity_name                   IN     VARCHAR2,
120     p_entity_attr_id                IN OUT NOCOPY NUMBER,
121     p_mixnmatch_enabled             IN     VARCHAR2,
122     p_actual_content_source         IN     VARCHAR2,
123     x_return_status                 IN OUT NOCOPY VARCHAR2
124 );
125 
126 /**
127  * FUNCTION CheckUserUpdatePrivilege
128  *
129  * DESCRIPTION
130  *   Check if user has privilege to update a third party record.
131  *
132 
133  + SSM SST Integration and Extension                                                         +
134  + This procedure will also be called for checking update privilege for other source systems'+
135  +                                                                                           +
136 
137  *
138  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
139  *
140  * ARGUMENTS
141  *   IN:
142  *     p_actual_content_source      Actual content source.
143  *   OUT:
144  *     x_return_status              Return FND_API.G_RET_STS_ERROR if the
145  *                                  user under this site/application/
146  *                                  responsibility is not allowed to create
147  *                                  user-entered data for this entity.
148  *
149  * NOTES
150  *   The procedure can only be called for other entities like HZ_CONTACT_POINTS,
151  *   HZ_LOCATIONS etc.
152  *
153  * MODIFICATION HISTORY
154  *
155  *   03-01-2002    Jianying Huang       o Created.
156  *   12-20-2004    Rajib Ranjan Borah   o SSM SST Integration and Extension.
157  *                                        Added parameters p_entity_name,
158  *                                        p_new_actual_content_source
159  */
160 
161 PROCEDURE CheckUserUpdatePrivilege (
162     p_actual_content_source         IN     VARCHAR2,
163     p_new_actual_content_source     IN     VARCHAR2,
164     p_entity_name                   IN     VARCHAR2,
165     x_return_status                 IN OUT NOCOPY VARCHAR2
166 );
167 
168 /**
169  * FUNCTION isDataSourceSelected
170  *
171  * DESCRIPTION
172  *   Internal use only!!!
173  *   Return 'Y' if the data source has been selected.
174  *
175  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
176  *
177  * ARGUMENTS
178  *   IN:
179  *     p_selected_datasources       A list of selected data sources. You can
180  *                                  get it via HZ_MIXNM_UTILITY.
181  *     p_actual_content_source      Actual content source.
182  *
183  * NOTES
184  *   The procedure can only be called for other entities like HZ_CONTACT_POINTS,
185  *   HZ_LOCATIONS etc. It can not be called on party profiles HZ_ORGANIZATION_PROFILES,
186  *   HZ_PERSON_PROFILES.
187  *
188  * MODIFICATION HISTORY
189  *
190  *   03-01-2002    Jianying Huang   o Created.
191  */
192 
193 FUNCTION isDataSourceSelected(
194 --  p_selected_datasources          IN     VARCHAR2,
195     p_entity_name                   IN     VARCHAR2,
196     p_actual_content_source         IN     VARCHAR2
197 ) RETURN VARCHAR2;
198 
199 /**
200  * FUNCTION ValidateContentSource
201  *
202  * DESCRIPTION
203  *   Validate content source type.
204  *
205  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
206  *
207  * ARGUMENTS
208  *   IN:
209  *     p_api_version                API version. 'V1' is for V1 API. 'V2' is for V2 API.
210  *     p_create_update_flag         Create or update flag. 'C' is for create. 'U' is for
211  *                                  update.
212  *     p_check_update_privilege     Check if user has privilege to update third party data.
213  *     p_content_source_type        Content source type.
214  *     p_old_content_source_type    Old content source type.
215  *     p_actual_content_source      Actual content source.
216  *     p_old_actual_content_source  Old actual content source.
217  *   IN/OUT:
218  *     x_return_status              Return FND_API.G_RET_STS_ERROR if the
219  *                                  user under this site/application/
220  *                                  responsibility is not allowed to create
221  *                                  user-entered data for this entity.
222  *
223  * NOTES
224  *
225  * MODIFICATION HISTORY
226  *
227  *   03-01-2002    Jianying Huang       o Created.
228  *   01-03-2005    Rajib Ranjan Borah   o SSM SST Integration and Extension.
229  *                                        Added parameter p_entity_name.
230  */
231 
232 PROCEDURE ValidateContentSource (
233     p_api_version                   IN     VARCHAR2,
234     p_create_update_flag            IN     VARCHAR2,
235     p_check_update_privilege        IN     VARCHAR2 := 'Y',
236     p_content_source_type           IN     VARCHAR2,
237     p_old_content_source_type       IN     VARCHAR2 := NULL,
238     p_actual_content_source         IN     VARCHAR2,
239     p_old_actual_content_source     IN     VARCHAR2 := NULL,
240     p_entity_name                   IN     VARCHAR2,
241     x_return_status                 IN OUT NOCOPY VARCHAR2
242 );
243 
244 /**
245  * FUNCTION AssignDataSourceDuringCreation
246  *
247  * DESCRIPTION
248  *   Assign data source during entity creation. Check validity of the data
249  *   source and check if user has privilege to create user-entered data.
250  *
251  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
252  *
253  * ARGUMENTS
254  *   IN:
255  *     p_entity_name                Entity name. Can not be party profiles.
256  *     p_entity_attr_id             Entity id. Entity id is used only for
257  *                                  performance consideration. It can speed
258  *                                  the query if it is passed.
259  *     p_mixnmatch_enabled          'Y'/'N' flag to indicate if mix-n-match
260  *                                  if enabled for this entity. You can get
261  *                                  the info. via HZ_MIXNM_UTILITY.
262  *     p_selected_datasources       A list of selected data sources. You can
263  *                                  get it via HZ_MIXNM_UTILITY.
264  *     p_content_source_type        Content source type.
265  *     p_actual_content_source      Actual content source.
266  *   OUT:
267  *     x_is_datasource_selected     Return 'Y'/'N' to indicate if the data
268  *                                  source is visible.
269  *     x_return_status              Return FND_API.G_RET_STS_ERROR if any
270  *                                  validation fails.
271  *
272  * NOTES
273  *   The procedure can only be called for other entities like HZ_CONTACT_POINTS,
274  *   HZ_LOCATIONS etc. It can not be called on party profiles HZ_ORGANIZATION_PROFILES,
275  *   HZ_PERSON_PROFILES.
276  *
277  * MODIFICATION HISTORY
278  *
279  *   03-01-2002    Jianying Huang   o Created.
280  */
281 
282 PROCEDURE AssignDataSourceDuringCreation (
283     p_entity_name                   IN     VARCHAR2,
284     p_entity_attr_id                IN OUT NOCOPY NUMBER,
285     p_mixnmatch_enabled             IN     VARCHAR2,
286     p_selected_datasources          IN     VARCHAR2,
287     p_content_source_type           IN OUT NOCOPY VARCHAR2,
288     p_actual_content_source         IN OUT NOCOPY VARCHAR2,
289     x_is_datasource_selected        OUT    NOCOPY VARCHAR2,
290     x_return_status                 IN OUT NOCOPY VARCHAR2,
291     p_api_version                   IN     VARCHAR2 := 'V2'
292 );
293 
294 /**
295  * FUNCTION isMixNMatchEnabled
296  *
297  * DESCRIPTION
298  *    Is mix-n-match is enabled in the given entity.
299  *
300  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
301  *
302  * ARGUMENTS
303  *   IN:
304  *     p_entity_name                 Entity name.
305  *     p_called_from_policy_function A flag to indicate if the procedure is called
306  *                                   from policy function.
307  *   IN/OUT:
308  *     p_entity_attr_id              Entity Id.
309  *
310  * NOTES
311  *
312  * MODIFICATION HISTORY
313  *
314  *   05-01-2002    Jianying Huang   o Created
315  */
316 
317 FUNCTION isMixNMatchEnabled (
318     p_entity_name                   IN     VARCHAR2,
319     p_entity_attr_id                IN OUT NOCOPY NUMBER,
320     p_called_from_policy_function   IN     VARCHAR2 := 'N'
321 ) RETURN VARCHAR2;
322 
323 /**
324  * PROCEDURE updateSSTProfile
325  *
326  * DESCRIPTION
327  *    Return new SST record to create / update SST profile.
328  *
329  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
330  *
331  * ARGUMENTS
332  *   IN:
333  *     p_create_update_flag         Create update flag.
334  *     p_create_update_sst_flag     Create update SST profile flag.
335  *     p_raise_error_flag           Raise error flag.
336  *     p_party_type                 Party type.
337  *     p_party_id                   Party Id.
338  *     p_new_person_rec             New person record.
339  *     p_old_person_rec             New person record.
340  *     p_sst_person_rec             Current SST person record.
341  *     p_new_organization_rec       New organization record.
342  *     p_old_organization_rec       New organization record.
343  *     p_sst_organization_rec       Current SST organization record.
344  *     p_data_source_type           Comming data source type.
345  *   IN/OUT:
346  *     p_new_sst_person_rec         New SST person record.
347  *     p_new_sst_organization_rec   New SST organization record.
348  *     x_return_status              Return status.
349  *
350  * NOTES
351  *   The procedure should only be called if the mix-n-match is enable for
352  *   the entity.
353  *
354  * MODIFICATION HISTORY
355  *
359 PROCEDURE updateSSTProfile (
356  *   05-01-2002    Jianying Huang   o Created
357  */
358 
360     p_create_update_flag            IN     VARCHAR2,
361     p_create_update_sst_flag        IN     VARCHAR2,
362     p_raise_error_flag              IN     VARCHAR2,
363     p_party_type                    IN     VARCHAR2,
364     p_party_id                      IN     NUMBER,
365     p_new_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE
366                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_PERSON_REC,
367     p_old_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE
368                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_PERSON_REC,
369     p_sst_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE,
370     p_new_sst_person_rec            IN OUT NOCOPY HZ_PARTY_V2PUB.PERSON_REC_TYPE,
371     p_new_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE
372                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_ORGANIZATION_REC,
373     p_old_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE
374                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_ORGANIZATION_REC,
375     p_sst_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE,
376     p_new_sst_organization_rec      IN OUT NOCOPY HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE,
377     p_data_source_type              IN     VARCHAR2,
378     x_return_status                 IN OUT NOCOPY VARCHAR2
379 );
380 
381 /**
382  * PROCEDURE updateSSTPerProfile
383  *
384  * DESCRIPTION
385  *    Return new SST record to create / update person SST profile.
386  *
387  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
388  *
389  * ARGUMENTS
390  *   IN:
391  *     p_create_update_flag         Create update flag.
392  *     p_create_update_sst_flag     Create update SST profile flag.
393  *     p_raise_error_flag           Raise error flag.
394  *     p_party_type                 Party type.
395  *     p_party_id                   Party Id.
396  *     p_new_person_rec             New person record.
397  *     p_old_person_rec             New person record.
398  *     p_sst_person_rec             Current SST person record.
399  *     p_data_source_type           Comming data source type.
400  *   IN/OUT:
401  *     p_new_sst_person_rec         New SST person record.
402  *     x_return_status              Return status.
403  *
404  * NOTES
405  *   The procedure should only be called if the mix-n-match is enable for
406  *   the entity.
407  *
408  * MODIFICATION HISTORY
409  *
410  *   05-01-2002    Jianying Huang   o Created
411  */
412 
413 PROCEDURE updatePerSSTProfile (
414     p_create_update_flag            IN     VARCHAR2,
415     p_create_update_sst_flag        IN     VARCHAR2,
416     p_raise_error_flag              IN     VARCHAR2,
417     p_party_id                      IN     NUMBER,
418     p_new_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE
419                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_PERSON_REC,
420     p_old_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE
421                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_PERSON_REC,
422     p_sst_person_rec                IN     HZ_PARTY_V2PUB.PERSON_REC_TYPE,
423     p_new_sst_person_rec            IN OUT NOCOPY HZ_PARTY_V2PUB.PERSON_REC_TYPE,
424     p_data_source_type              IN     VARCHAR2,
425     x_return_status                 IN OUT NOCOPY VARCHAR2
426 );
427 
428 /**
429  * PROCEDURE updateSSTOrgProfile
430  *
431  * DESCRIPTION
432  *    Return new SST record to create / update organization SST profile.
433  *
434  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
435  *
436  * ARGUMENTS
437  *   IN:
438  *     p_create_update_flag         Create update flag.
439  *     p_create_update_sst_flag     Create update SST profile flag.
440  *     p_raise_error_flag           Raise error flag.
441  *     p_party_type                 Party type.
442  *     p_party_id                   Party Id.
443  *     p_new_organization_rec       New organization record.
444  *     p_old_organization_rec       New organization record.
445  *     p_sst_organization_rec       Current SST organization record.
446  *     p_data_source_type           Comming data source type.
447  *   IN/OUT:
448  *     p_new_sst_organization_rec   New SST organization record.
449  *     x_return_status              Return status.
450  *
451  * NOTES
452  *   The procedure should only be called if the mix-n-match is enable for
453  *   the entity.
454  *
455  * MODIFICATION HISTORY
456  *
457  *   05-01-2002    Jianying Huang   o Created
458  */
459 
460 PROCEDURE updateOrgSSTProfile (
461     p_create_update_flag            IN     VARCHAR2,
462     p_create_update_sst_flag        IN     VARCHAR2,
463     p_raise_error_flag              IN     VARCHAR2,
464     p_party_id                      IN     NUMBER,
465     p_new_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE
466                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_ORGANIZATION_REC,
467     p_old_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE
468                                              DEFAULT HZ_PARTY_V2PUB.G_MISS_ORGANIZATION_REC,
469     p_sst_organization_rec          IN     HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE,
473 );
470     p_new_sst_organization_rec      IN OUT NOCOPY HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE,
471     p_data_source_type              IN     VARCHAR2,
472     x_return_status                 IN OUT NOCOPY VARCHAR2
474 
475 /**
476  * PROCEDURE getDictIndexedNameList
477  *
478  * DESCRIPTION
479  *    Split a new list into non-restricted attributes list and restricted
480  *    attributes list.
481  *
482  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
483  *
484  * ARGUMENTS
485  *   IN:
486  *     p_entity_name                Entity name.
487  *     p_name_list                  Attribute name list.
488  *   OUT:
489  *     x_restricted_name_list       Restricted attributes' name list.
490  *     x_nonrestricted_name_list    Non-Restricted attributes' name list.
491  *
492  * NOTES
493  *   The procedure should only be called if the mix-n-match is enable for
494  *   the entity.
495  *
496  * MODIFICATION HISTORY
497  *
498  *   05-01-2002    Jianying Huang   o Created
499  */
500 
501 PROCEDURE getDictIndexedNameList (
502     p_entity_name                   IN     VARCHAR2,
503     p_name_list                     IN     INDEXVARCHAR30List,
504     x_restricted_name_list          OUT    NOCOPY INDEXVARCHAR30List,
505     x_nonrestricted_name_list       OUT    NOCOPY INDEXVARCHAR30List
506 );
507 
508 /**
509  * PROCEDURE areSSTColumnsUpdeable
510  *
511  * DESCRIPTION
512  *    Return a list to indicate which SST attributes are updatable and which are not.
513  *
514  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
515  *
516  * ARGUMENTS
517  *   IN:
518  *     p_party_id                   Party Id.
519  *     p_entity_name                Entity name.
520  *     p_attribute_name_list        Attribute name list.
521  *     p_value_is_null_list         'Y' if the corresponding SST column is null.
522  *     p_data_source_type           Comming data source.
523  *     p_raise_error_flag           Raise error flag.
524  *     p_known_dict_id              'Y' if use knew entity id.
525  *   IN/OUT:
526  *     x_return_status              Return status.
527  *   OUT:
528  *     x_updatable_flag_list        Updatable list.
529  *
530  * NOTES
531  *   The procedure should only be called if the mix-n-match is enable for
532  *   the entity.
533  *
534  * MODIFICATION HISTORY
535  *
536  *   05-01-2002    Jianying Huang   o Created
537  */
538 
539 PROCEDURE areSSTColumnsUpdeable (
540     p_party_id                      IN     NUMBER,
541     p_entity_name                   IN     VARCHAR2,
542     p_attribute_name_list           IN     INDEXVARCHAR30List,
543     p_value_is_null_list            IN     INDEXVARCHAR1List,
544     p_data_source_type              IN     VARCHAR2 := 'SST',
545     x_updatable_flag_list           OUT    NOCOPY INDEXVARCHAR1List,
546     x_return_status                 IN OUT NOCOPY VARCHAR2,
547     p_raise_error_flag              IN     VARCHAR2 DEFAULT 'N',
548     p_known_dict_id                 IN     VARCHAR2 DEFAULT 'N'
549 );
550 
551 /**
552  * PROCEDURE LoadDataSources
553  *
554  * DESCRIPTION
555  *    Load data sources for a given entity.
556  *
557  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
558  *
559  * ARGUMENTS
560  *   IN:
561  *     p_entity_name                 Entity name.
562  *     p_called_from_policy_function A flag to indicate if the procedure is called
563  *                                   from policy function.
564  *   IN/OUT:
565  *     p_entity_attr_id              Entity Id.
566  *     p_mixnmatch_enabled           If the mix-n-match is enabled for this entity.
567  *     p_selected_datasources        Select data sources for this entity.
568  *
569  * NOTES
570  *
571  * MODIFICATION HISTORY
572  *
573  *   05-01-2002    Jianying Huang   o Created
574  */
575 
576 PROCEDURE LoadDataSources (
577     p_entity_name                   IN     VARCHAR2,
578     p_entity_attr_id                IN OUT NOCOPY NUMBER,
579     p_mixnmatch_enabled             IN OUT NOCOPY VARCHAR2,
580     p_selected_datasources          IN OUT NOCOPY VARCHAR2,
581     p_called_from_policy_function   IN     VARCHAR2 := 'N'
582 );
583 
584 /**
585  * FUNCTION getSelectedDataSources
586  *
587  * DESCRIPTION
588  *    Return selected data sources for a given entity. The
589  *    function is created for policy function. For anywhere
590  *    else, you should call LoadDataSources.
591  *
592  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
593  *
594  * ARGUMENTS
595  *   IN:
596  *     p_entity_name                Entity name.
597  *   IN/OUT:
598  *     p_entity_attr_id             Entity Id.
599  *
600  * NOTES
601  *
602  * MODIFICATION HISTORY
603  *
604  *   05-01-2002    Jianying Huang   o Created
605  */
606 
607 FUNCTION getSelectedDataSources (
608     p_entity_name                   IN     VARCHAR2,
609     p_entity_attr_id                IN OUT NOCOPY NUMBER
610 ) RETURN VARCHAR2;
611 
612 /**
613  * FUNCTION isEntityUserCreatable
614  *
615  * DESCRIPTION
616  *    Return if user can create user-entered data.
617  *
618  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
619  *
620  * ARGUMENTS
621  *   IN:
622  *     p_entity_name                Entity name.
623  *   IN/OUT:
624  *     p_entity_attr_id             Entity Id.
625  *
626  * NOTES
627  *   The procedure should only be called if the mix-n-match is enable for
628  *   the entity.
629  *
630  * MODIFICATION HISTORY
631  *
632  *   05-01-2002    Jianying Huang   o Created
633  */
634 
635 FUNCTION isEntityUserCreatable (
636     p_entity_name                   IN     VARCHAR2,
637     p_entity_attr_id                IN OUT NOCOPY NUMBER
638 ) RETURN VARCHAR2;
639 
640 --------------------------------------------------------------------------
641 -- the following procedures are called by mix-n-match concurrent program.
642 --------------------------------------------------------------------------
643 
644 /**
645  * PROCEDURE conc_main
646  *
647  * DESCRIPTION
648  *   Main concurrent program for mix-n-match.
649  *
650  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
651  *
652  * IN:
653  *   p_commit_size                  Commit size.
654  *   p_num_of_worker                Number of workers.
655  * OUT:
656  *   errbuf                         Buffer for error message.
657  *   retcode                        Return code.
658  *
659  * MODIFICATION HISTORY
660  *
661  *   04-30-2002    Jianying Huang   o Created.
662  */
663 
664 PROCEDURE conc_main (
665     errbuf                          OUT NOCOPY    VARCHAR2,
666     retcode                         OUT NOCOPY    VARCHAR2,
670 
667     p_commit_size                   IN     VARCHAR2,
668     p_num_of_worker                 IN     VARCHAR2
669 );
671 /**
672  * PROCEDURE conc_sub
673  *
674  * DESCRIPTION
675  *   Sub concurrent program for mix-n-match.
676  *
677  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
678  *
679  * IN:
680  *   p_entity_type                  Entity type.
681  *   p_from_id                      From id.
682  *   p_to_id                        To id.
683  *   p_commit_size                  Commit size.
684  * OUT:
685  *   errbuf                         Buffer for error message.
686  *   retcode                        Return code.
687  *
688  * MODIFICATION HISTORY
689  *
690  *   04-30-2002    Jianying Huang   o Created.
691  */
692 
693 PROCEDURE conc_sub (
694     errbuf                          OUT NOCOPY   VARCHAR2,
695     retcode                         OUT NOCOPY   VARCHAR2,
696     p_entity_type                   IN     VARCHAR2,
697     p_from_id                       IN     VARCHAR2,
698     p_to_id                         IN     VARCHAR2,
699     p_commit_size                   IN     VARCHAR2
700 );
701 
702 /**
703  * PROCEDURE
704  *     create_exceptions
705  *
706  * DESCRIPTION
707  *     Creates records in HZ_WIN_SOURCE_EXCEPTIONS when a party (organization/ person)
708  *     is created from non-user_entered source systems and no prior user-entered profile
709  *     exist for that party.
710  *
711  * EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
712  *     HZ_MIXNM_API_DYNAMIC_PKG.initAttributeList
713  *     HZ_MIXNM_UTILITY.cacheSetupForPartyProfiles
714  *     HZ_MIXNM_UTILITY.getEntityAttrId
715  *     HZ_MIXNM_UTILITY.getDataSourceRanking
716  *
717  * ARGUMENTS
718  *   IN:
719  *     p_party_type                Either 'ORGANIZATION' or 'PERSON'
720  *     p_organization_rec
721  *     p_person_rec
722  *     p_third_party_content_source
723  *     p_party_id
724  *   OUT:
725  *
726  * NOTES
727  *     This will be called only from HZ_PARTY_V2PUB.do_create_party.
728  *     And only when a new party is created by a non-user_entered source system.
729  *
730  * MODIFICATION HISTORY
731  *
732  *   12-30-2004    Rajib Ranjan Borah  o SSM SST Integration and Extension. Created.
733  *
734  */
735 
736 PROCEDURE create_exceptions (
737   p_party_type                   IN      VARCHAR2,
738   p_organization_rec             IN      HZ_PARTY_V2PUB.ORGANIZATION_REC_TYPE
739                            DEFAULT       HZ_PARTY_V2PUB.G_MISS_ORGANIZATION_REC,
740   p_person_rec                   IN      HZ_PARTY_V2PUB.PERSON_REC_TYPE
741                            DEFAULT       HZ_PARTY_V2PUB.G_MISS_PERSON_REC,
742   p_third_party_content_source   IN      VARCHAR2,
743   p_party_id                     IN      NUMBER
744 );
745 
746 Procedure populateMRRExc(
747 	p_entity_name                   IN     VARCHAR2,
748 	p_data_source_type              IN     VARCHAR2,
749 	p_party_id			IN	NUMBER
750 );
751 
752 Function getUserRestriction(
753 	p_entity_attr_id IN NUMBER
754 ) Return VARCHAR2;
755 
756 Function getUserOverwrite(
757         p_entity_attr_id IN NUMBER,
758         p_rule_id        IN NUMBER
759 ) Return VARCHAR2;
760 
761 
762 Function getGroupMeaningList(
763 	p_entity IN VARCHAR2,
764         p_group IN VARCHAR2
765 ) Return VARCHAR2;
766 
767 END HZ_MIXNM_UTILITY;