function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
NCEE_AndrewNCEE_Andrew 

Reporting: checking two fields to each other

I'm trying to create a report that will give me every contact whose Mailing Address is different from their Account's Shipping Address.

 

Any ideas how to do this through Salesforce's Report tool?

NikiVNikiV

The first thought that comes to mind is using custom formula fields.  You could create a formula on Contact that compares each mailing address field to the corresponding account's shipping address field.  Then run a report using that field.  For example:

 

IF(MailingStreet != Account.ShippingStreet , 'different',

IF(MailingCity != Account.ShippingCity, 'different',

IF(MailingState != Account.ShippingState, 'different',

IF(MailingPostalCode != Account.ShippingPostalCode, 'different',

IF(MailingCountry != Account.ShippingCountry, 'different',

'')))))

 

You can then run a report showing all Contact's where this field = different.  If you wanted to be fancy you could label each to show the field that is different and then the report criteria could be where this field <> blank.

 

Hope that helps.