You need to sign in to do that
Don't have an account?
laxman raj
how to insert a new record in same object by using a trigger
trigger insertrecord on x__c (before insert) {
list<x__c> cu=trigger.new;
for(x__c xg:trigger.new)
{
xg.name='hjh';
insert xg;
}
}
list<x__c> cu=trigger.new;
for(x__c xg:trigger.new)
{
xg.name='hjh';
insert xg;
}
}
You can refer below code:
If this solves your problem, kindly mark it as the best answer.
Thanks,
Vatsal