Ajouter aux favorisGorav Seth (Ashoka) (Initialement publié par Rick Haag)18 août 2017, 15:59Looping and Fast Updates.pngRick HaagLoops, Fast Updates and CPU Timeouts I have done a bit of research to find if there is some way to mass update records in an Sobject Collection Variable "without" Looping through each recordAssigning a value to an Sobject VariableAdding to a final collection and finally using the Fast Update element to write the new value. Is it possible to simply run a Fast Lookup to build the collection and then update a single column in the collection, with the same value for every record, then Fast Update? Example:Fast Lookup (Opportunity: ID & CustomCheckbox__c).After the fast lookup, update resulting collection to where "Custom Checkbox" in all records of the collection is set to TRUE.Fast Update Is there some way to do this without looping through each record in the collection? I have looked in to Collection Variables, using 1 assignment to set values in an Sobject Collection Variable, but that isn't an option (or I haven't been able to make it work). Why not just run the loop option, you may ask?It seems for collections somewhere between 600 & 700 records, looping through records triggers a Limit Warning or CPU Timeout, and thus the flow fails.Afficher plus2 commentairesChargement de commentaires supplémentaires...Gorav Seth (Ashoka)18 août 2017, 15:59https://success.salesforce.com/0D53A00003DKPimAjouter un commentaireRédiger un commentaire...GrasItaliqueSoulignerBarréListe à pucesListe numérotéeAjouter un lienBloc de codeInsérer une imageJoindre des fichiersURL du lienAnnulerEnregistrer0/9000Répondre
Rick HaagLoops, Fast Updates and CPU Timeouts I have done a bit of research to find if there is some way to mass update records in an Sobject Collection Variable "without" Looping through each recordAssigning a value to an Sobject VariableAdding to a final collection and finally using the Fast Update element to write the new value. Is it possible to simply run a Fast Lookup to build the collection and then update a single column in the collection, with the same value for every record, then Fast Update? Example:Fast Lookup (Opportunity: ID & CustomCheckbox__c).After the fast lookup, update resulting collection to where "Custom Checkbox" in all records of the collection is set to TRUE.Fast Update Is there some way to do this without looping through each record in the collection? I have looked in to Collection Variables, using 1 assignment to set values in an Sobject Collection Variable, but that isn't an option (or I haven't been able to make it work). Why not just run the loop option, you may ask?It seems for collections somewhere between 600 & 700 records, looping through records triggers a Limit Warning or CPU Timeout, and thus the flow fails.Afficher plus