Duplicate entries when the Source mail attribute is changed
Created: 2012-04-20 08:09:59Modified: 2017-04-28 10:44:13
Tags: Active Directory Troubleshooting UnitySync
Some Create/Join connections use the join query of Destination email equals Source email (mail=^mail^). This query is likely to cause duplicate Destination objects if the Source mail attribute is changed. This is because changing the Source primary email address makes the object look like a new object to UnitySync based on the join query, and therefore a new object is created. To avoid this, you must use an expanded join query.
Usually, including proxyaddresses in your join query will alleviate this issue. Our recommended join query is:
(|(mail=^mail^)(proxyaddresses=[proxyaddresses]))
This query compares both mail attributes and proxyaddresses attributes. So, even if the Source email address is changed, as long as it is still listed as a Source proxyaddress, it will link to the previously created Destination object.
In some cases, however, the mail attribute is changed and not reflected in any of the proxyaddresses. In order to build a join query that works for you, you must identify appropriate Source and Destination attributes that will match even if the Source mail attribute is altered. The attributes must be populated and contain unique values, allowing the Join to work as designed, matching Source objects to the Destination. If you must use a different join query, we recommend that you contact support@dirwiz.com for assistance in building one that works for your specific needs.
NOTE: If you cannot identify appropriate additional Source and Destination attributes to use, it will be necessary to manufacture them, so to speak. In this case, you would pick a source attribute SourceAttribX (that contains a guaranteed unique value in each source object) and set up your existing connection to sync that value to all Destination objects using a custom mapping i.e DestAttribY=SourceAttribX . The first time you run with this mapping, you leave your mail/mail indexes in place. Once the above mapping has been applied on the initial sync run, you now have these alternate attributes set up and ready for use in your join query (DestAttribY=SourceAttribX). Additionally, all new ADD’s will populate the DestAttribY as required for this join query to work ongoing. Again, we suggest you contact support@dirwiz.com for assistance with this process and building your new join query.
Important Notes
- The first time you run the connection after changing your join query, we strongly recommend you disable Synchronization and enable Simulation on the General tab to verify the Simulation shows all MOD’s and no unexpected ADD’s. In the event of configuration mistakes, Simulation may show mass deletes, mass adds or other unexpected results. If you are concerned by your Simulation results, do not run a real Synchronization until Support has reviewed your Simulation log files. Please see Forwarding logs or data files to Support for additional information on providing your log files to Support.
- You ideally want make the above changes before any more Source email addresses are changed as the mail=^mail^ join query will continue to result in duplicates when any source email address is changed. Once you’ve adjusted your query, modification of the Source email address will no longer result in duplicates. *The attribute DestAttribY, if used, must be indexed and visible in the Global Catalog.
For more detailed information on join queries, see the Sync/Join Mode Join and Both - Create and Join knowledge base article.