Questions tagged [iteration]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
1answer
2k views

How to fetch the value inside a list item(not having an id since created dynamically) in lightning?

I am creating a a list using aura:iteration: <aura:iteration var="pf" items="{!v.family}" indexVar="ind"> <li class="slds-dropdown__item"> <a href="javascript:void(0);" role="...
2
votes
1answer
552 views

Batch Job with Custom Iterable throwing error First error: Invalid conversion from runtime type CustomIterable to System.Iterable

I get the error First error: Invalid conversion from runtime type CustomIterable to System.Iterable when trying to use a customer iterable in a batch job. My custom iterable class: global class ...
0
votes
3answers
1k views

Modify collection during iteration

I have below code where I need to modify the List during iteration. It throws error. can someone suggest a way out in this case? **Error ** System.FinalException: Cannot modify a collection while it ...
3
votes
2answers
331 views

Pagination Using Iterator Limit

I have to paginate total of 4000-5000 records with 20 records per page. I am using a wrapper class type List. This list would be displayed on a pageblocktable. I CANT use OFFSET because offset has a ...
1
vote
1answer
240 views

<aura:iteration> How to properly add commas on fields

I have an aura iteration using dynamic fields in this code snippet. <aura:iteration items="{!v.qResults}" var="q"> <li id="{!q.Id}" class="slds-dropdown__item" role="menuitem ...
3
votes
1answer
278 views

Using next method in iterator

In my code below: List<Skill__c> skilist = [ select Id,Name from Skill__c where Skill__c.Id IN:sl.keySet()]; Iterator<Skill__c> iter = skilist.iterator(); List<Job_Opening_Skill__c&...
0
votes
1answer
8k views

Copy a list to another list

I have a custom object called skill_Review and I am creating a list in my controller using: List<Skill_Review__c> skillRev = new List<Skill_Review__c> List<Skill_Review__c> ...
2
votes
1answer
129 views

Updates from nested apex repeat in Visualforce not being posted to server correctly

I am having a custom object where there is a list within a list within a list. On the Visualforce page I am presenting it using an apex:repeat and apex:inputText fields. When I try to change and ...
2
votes
3answers
932 views

Iterate over queried lookup fields

Example: Opportunity Opp = [SELECT Name, Status__c, Zone__c, Invoice__r.Amount__c, Invoice__r.Date__c FROM Opportunity WHERE ID ='006a12nlfoenlew']; I need to iterate over each field and see if the ...
2
votes
2answers
1k views

Iterating inside a Map

Big picture, upon importing a csv, we have some unique Id's that may be tied to an account already in our instance. I can iterate over a list with no issue and to find any unique Id's with a matching ...
0
votes
1answer
522 views

Aura iteration too show value in two columns [closed]

i need to show in two grids how to use aura iteration to do it. suppose list is like ab,cd,ef,gh,ij,kl,mn then the ui should values like ab cd ef gh ij kl mn please suggest if you ...
9
votes
1answer
13k views

Nested aura:iteration to dynamically get fields

I am trying to dynamically create a data table with two arrays (SObject array and a String array which has field API name). The two arrays are Contact[] and String[], where String[] consists of ["Id",...
1
vote
1answer
314 views

Is aura:iteration reactive?

Say I have multiple components nested under each other, one takes collection of Accounts, the component under Account takes a collection of Contacts. Say I want to programmatically remove one of the ...
8
votes
2answers
476 views

Why aren't iterators in batch jobs lazy-loaded?

I have a batch job that needs to callout to an external web service and retrieve a variable number of records. Seems like a perfect use-case to have an iterator which performs the callouts until there ...
9
votes
4answers
7k views

How to use <force:inputField> and <force:outputField> inside an <aura:iteration>

Here @Peter describes a very cool way to use a <force:inputField ... /> together with <aura:attribute name="YourObjectType" type="YourObjectType" default="{ sobjectType: '...
8
votes
1answer
5k views

Stop Batch Process

Good day everyone, I have created a batch process. Let say I have thousands of records to process. Now what i want is when there is an error encounter or some problem found in the data during the ...
1
vote
1answer
2k views

Get Data from batch iterable

Good day everyone, Maybe this question is basic for everyone but I'm having a problem with it, so I'm asking for help. I have created a BATCH ITERABLE . global with sharing class batchProcessor ...
2
votes
0answers
428 views

Get first row of CSV data in salesforce and use for mapping

I want to get data from csv and upload it to salesforce. I use this link http://www.blueengine.com.au/?p=40#comment-271 and http://developer.financialforce.com/customizations/importing-large-csv-...
4
votes
1answer
335 views

How to get Map collection out of a list?

I currently have a multi-demensional map/list object that is defined like this: Map <Id,List <Map <Id,Custom_Inventory__c> >> complexMap = getComplexMapObject(); The object was ...
3
votes
2answers
162 views

How can I filter through object using 2 separate fields as unique identifiers?

I have a custom object (we'll call it RS__c), and it theoretically has a 1 to 1 relationship to OpportunityLineItems (it is not possible to create a reference field directly to create this ...
4
votes
1answer
4k views

Number of iterations exceeded - Flow Error

I have a flow that loops through Opportunity Line Items. When the number of line items get large it get an error in my flow. The UI gives the following message "You or your organization has exceeded ...
1
vote
2answers
1k views

Aggregate query does not support queryMore() [duplicate]

I have a requirement to send mass emails to certain Users of current day created records daily. I am unable to do that with below code. Getting error : Aggregate query does not support queryMore() ...
6
votes
1answer
3k views

Why is my Lightning aura:iterate component not iterating?

Currently working through the Create a Standalone Lightning App tutorial, which seems a good introduction to SFDC Lightning, but not entirely flawless. I have this component <aura:component ...
3
votes
1answer
430 views

This map cannot be used in an iteration because the keys cannot be sorted

In my apex code I am adding some value into map. And I am trying to loop through the map on VF page using apex:repeat but I am getting an error that This map cannot be used in an iteration because ...