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
Raju SudheerRaju Sudheer 

There is two objects company and employee , employee has lookup relation from company, and it has one pick list field ,which hold VP,CEO,CFO,etc when you create record in employee ,I need only VP records count that should be update in company

SonamSonam (Salesforce Developers) 
Hi,

This can be accomplished using a trigger on employee  object such that it can be used to update the company when the picklist value on employee is as mentioned in your requirement.

sample code available on the thread:https://developer.salesforce.com/forums/?id=906F00000008yVgIAI