10-31-2024 10:30 AM
I want to use FieldCopyUnique to save a different Mailing Address to Other Address. So, it looks like I need to define each field individually (Other Street, Other City, Other State, Other Country), but I need to make sure I'm keeping the Other Address populated with a complete address either the existing Other Address, or the Mailing Address.
So, would I need to use scoring where I only update if all the Other Address fields are not populated to make sure I'm not only updating the non-blank fields, essentially leaving the other address fields as is if there's a value?
And if FieldCopyUnique behaves like an update if empty, what what if both records have an Other Address fields, except on is missing the Country? For example Country is commonly blank for my US addresses. However, foreign countries are typically filled. So, how do I avoid populating the blank country field on the address that is retained?
Solved! Go to Solution.
11-01-2024 01:21 PM - edited 11-01-2024 01:22 PM
@michael-wtds - If I am understanding your question correctly, there are a couple items at play here, but I would first reccomend populating that country field for the US addresses using Modify so that you can avoid that potential pitfall. The being said, FieldCopyUnique Overwrite should be your friend here. This will take the unique value and overwrite the existing value in the mapped location. Whereas FieldCopyUnique will respect that update if empty logic for the field you are mapping to and leave it alone if it is currently populated. Does that answer your question?
11-01-2024 01:21 PM - edited 11-01-2024 01:22 PM
@michael-wtds - If I am understanding your question correctly, there are a couple items at play here, but I would first reccomend populating that country field for the US addresses using Modify so that you can avoid that potential pitfall. The being said, FieldCopyUnique Overwrite should be your friend here. This will take the unique value and overwrite the existing value in the mapped location. Whereas FieldCopyUnique will respect that update if empty logic for the field you are mapping to and leave it alone if it is currently populated. Does that answer your question?
11-04-2024 08:22 AM - edited 11-04-2024 08:28 AM
@Pugs_Validity Thank you for the guideance on this, and can you point me to the help documentation on Field Copy Unique Overwrite, as I didn't see this in the field rules page I was using.
https://knowledge.validity.com/s/articles/Field-Rules?language=en_US
For now it does look like Field Copy Unique, along with scoring is going to get me there. In my case if none of the Other Address fields are populated, and if Mailing Address is populated, then the FieldCopyUnique will update each selected field. This just keeps it very black and white, that if any Other Address field is populated, don't bother with an update.
To simplify the scoring, I created 2 custom fields in Salesforce that are true if any address field is populated (Street, City, State, Zip, Country), which I with the following formula:
Then in the Field Scoring, I checked to see if Mailing Address Populated is True, and Other Address Populated is False.
Eventually if I find that I have some lower quality Other Addresses that are very incomplete, I'll likely need to revisit this. But for now I have mostly blank Other Addresses in my data, and this seems to be the solution I need.
Thanks again for your feedback!
11-04-2024 02:35 PM
You have the right article, we likely need to add some additional clarification for that specificity. Additional clarity can be found in the 5.37.1 Release Notes. That's a creative workaround, I think your thought process seems sound as well. Let us know if anything else comes up!
Get industry news, expert insights, strategies, and hot tips, served up fresh every week.
Visit the Validity blog