I have a junction object which has a master detail relationship to account and market. This junction object can only be created from account. When user clicks new, Account will already be prefilled but user can only add a market if city field on market,which is a multiselect, contains the city selected on the account object otherwise it throws an error. How can i compare two lookup fields on insert?
You can do this with a validation rule. Your formula for your validation rule will probably be something like
Account.BillingCity <> Market__r.City__c
Edit for multi-select picklist: