Accenture interview question

database.statful

Interview Answer

Anonymous

May 28, 2020

database.stateful generally used with batch apex as in batch apex methods are not holding the states, the value of one variable is not there in another method, if you list of a string with execute method nad try to fetch that in finish method, you cant as finish method doesn't know about this list. this issue can be solved using the database, stateful