With the Merge Dictionary, you determine the sequence of entities to merge, as well as view, update, and add seeded or custom entities.
You add entities as a child of another entity. The parent entity is merged before the child, and the foreign key of the child points to the parent.
You can delete custom entities from the Merge Dictionary. The data from deleted entities will not be merged during any merge process, and all child entities under the deleted entity will also be deleted.
See: Customizing the Merge Dictionary.
Before you add any Oracle application to the Merge Dictionary, you must:
Identify any entities that have foreign keys in the TCA Registry.
Create merge procedures by identifying the foreign keys for those entities.
This table describes the details of the entity that you are viewing, updating, or adding. What you can update depends on whether the entity is seeded or custom.
| Detail | Description |
|---|---|
| Entity | The name of the table that has a foreign key to the HZ_PARTIES table or a related table such as HZ_PARTY_SITES or HZ_CONTACT_POINTS. |
| Application | The Oracle application affected by the merge process. |
| Sequence | The order in which the entity is to be processed during a merge. |
| Parent Entity | The name of the table that the foreign key of the entity refers to. |
| Primary Key | The name of the primary key column for the entity. |
| Foreign Key | The name of the foreign key column which links the entity to its parent entity. |
| Description | A description of the entity, for example Party for HZ_PARTIES. |
| Description Columns | The name of the columns used to generate a description for the record, for example, PARTY_NAME for the HZ_PARTIES table. You can alternatively enter a complex concatenation or decode expression. The description columns are used in reports and logs. |
| Procedure Name | The name of the merge procedure, which must conform to the standard merge procedure signature. |
| Merge Records in Bulk | Whether or not the merge procedure is called once for every record or for all records in the table that references the merged party. If records are merged in bulk, you cannot assign child entities to this entity. |
| Additional Query Clause | A SQL clause that is used to specify additional filtering conditions for joining the table to the related parent entity. |
| Batch Merge Routine | Whether or not the merge procedure is a routine that should be processed in batch, for performance reasons. Generally, you should use this option if the table that this merge routine is created for has multiple foreign key references to TCA. This option lets you create one batch routine instead of a number of regular routines for each foreign key. |
You can customize the Merge Dictionary by including your own custom entities as part of the merge process, so that custom entities can be merged using standard merge rules or custom rules. You must develop the code to customize the merge procedures used by your custom applications and entities. Your custom merge procedure should:
Perform any required validations before you run the merge process.
Meet the processing requirements of your range of business activities.
Conform to the standard merge procedure signature. This table shows the parameters.
| Parameter | Usage | Data Type | Description |
|---|---|---|---|
| p_entity_name | IN | VARCHAR2 | Name of the entity being merged. |
| p_from_id | IN | NUMBER | Primary key ID of the merge-from record. |
| p_to_id | IN / OUT | NUMBER |
|
| p_from_fk_id | IN | NUMBER | Foreign key ID of the merge-from record. |
| p_to_fk_id | IN | NUMBER | Foreign key ID of the merge-to record. |
| p_parent_entitiy_name | IN | VARCHAR2 | Name of the parent entity. |
| p_batch_id | IN | NUMBER | Batch ID. |
| p_batch_party_id | IN | NUMBER | ID that uniquely identifies the batch and party record being merged. Use this ID to reference batch information. |
| x_return_status | IN / OUT | VARCHAR2 | Status of the call. Returned values are:
|
If the relationship between the parent and child entities involve more than one foreign key or is complex, you can enter an additional join condition in the merge procedure.
For example, the HZ_CONTACT_POINTS table can be associated with either a party or party sites based on the value of the owner_table_name. To associate HZ_CONTACT_POINTS with:
The HZ_PARTIES table
Enter the join condition as hz_contact_points.owner_table_name = HZ_PARTIES.
Define the foreign key as owner_table_id.
The HZ_PARTY_SITE table
Enter the join condition as hz_contact_points.owner_table_name = HZ_PARTY_SITE.
Define the foreign key as owner_table_id.