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
Sujan Kumar ReddySujan Kumar Reddy 

Can we write SOQL query in Validation rule?

Hi,

 

Interview question: Can we write SOQL query in validation rule? Can anybody answer it for me?

Best Answer chosen by Admin (Salesforce Developers) 

All Answers

Sujan Kumar ReddySujan Kumar Reddy

Hello JD,

 

Thanks for your reply, that means you mean to say that we cannot write and SOQL in validation rule ryte? Instead of that we need to write trigger?

mrajmraj

thats absolutely correct...