0 votes
11 views
What is Trigger.new?
in Technology by (189k points)

1 Answer

0 votes
Triger.new is a command which returns the list of records that have been added recently to the sObjects. To be more precise, those records will be returned which are yet to be saved to the database. Note that this sObject list is only available in insert and update triggers, and the records can only be modified in before triggers.

But just for your information, Trigger.old returns a list of the old versions of the sObject records. Note that this sObject list is only available in update and delete triggers.
by (189k points)

Related questions

0 votes
1 answer 12 views
0 votes
1 answer 12 views
12 views asked Nov 11, 2020 in Technology by JackTerrance (189k points)
0 votes
1 answer 21 views
21 views asked Nov 11, 2020 in Technology by JackTerrance (189k points)
0 votes
1 answer 16 views
0 votes
1 answer 16 views
0 votes
1 answer 15 views
0 votes
1 answer 13 views
0 votes
1 answer 10 views
10 views asked Nov 11, 2020 in Technology by JackTerrance (189k points)
0 votes
1 answer 19 views
0 votes
1 answer 11 views
0 votes
1 answer 17 views
0 votes
1 answer 13 views
0 votes
1 answer 23 views
0 votes
1 answer 11 views
0 votes
1 answer 11 views
0 votes
1 answer 17 views
0 votes
1 answer 12 views
0 votes
1 answer 9 views
0 votes
1 answer 12 views
12 views asked Nov 11, 2020 in Technology by JackTerrance (189k points)
0 votes
1 answer 16 views
0 votes
1 answer 24 views
0 votes
1 answer 12 views
...