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
kittu9kittu9 

How to controll trigger execution

How to execute a trigger only one time instead of executing for all records.

Yoganand GadekarYoganand Gadekar

Please provide more details on your exact requirement.

You can use static boolean variable in a class and set it at the begining of the trigger execution.

kittu9kittu9

I phased one question how can you control your trigger to execute only one time instead of for all records. that was the question.

Yoganand GadekarYoganand Gadekar

which record? 1st record?

then you can take that record as trigger.new[0].