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
Philip BonthaPhilip Bontha 

Dear all,need some help on validation rule.

There are two objects which have master-detail relationship.
Object1:Book__c
Object2:Price__c(MD relationship to Book__c)
on Book__c  i have a picklist field Type__c which have values Yes,No.
On Price__c I have a lookup field (PC__c) to user.
If i select the Type__c as "Yes" on Book__c then in the Price__c the PC__c field can't blank.

Please help on this.
Thanks in advance..!

Raju
VinayVinay (Salesforce Developers) 
You can try below snippet.  Kindly provide exact relationship field name and picklist field API names.
 
AND(ISPICKVAL(Type,'Yes'),ISBLANK(relationshipfield__r.PC__c))

Thanks,