You need to sign in to do that
Don't have an account?
bakum
How do i search a map(ID, sObject) for certain fields in the sObject values?
Hi, I've got a map(id, sObject). I need to search the map to find all the rows where sObject.field=XXX, and then throw that sObject onto a list of sObjects for a DML operation later in the script. I'm just at a loss how to do this. Any suggestions?
It might be of some value to know that the map could contain 1000 rows and sObject.field=XXX could be true four or five times in the map.
-mb
It might be of some value to know that the map could contain 1000 rows and sObject.field=XXX could be true four or five times in the map.
-mb
The only way I have figured out how to do this is to loop the entire map, and check each sObject for the value. If it exists, then pass that ID to another List of IDs, or the object to a set for processing later.